Update to the default MARC Bib-to-Inventory Instance MAP:
- todo
Script for updating such mapping:
-
MODDICORE-355Getting issue details...
STATUS
Steps:
- If library tenant is using default mapping rules with NO changes (no customizations), then call PUT /mapping-rules/marc-bib/restore endpoint
- If library tenant is using default mapping rules, WITH changes (local customization), then follow the next step
- Send a GET request to /mapping-rules/marc-bib to retrieve the mapping rules
Under 100, 110, 111, 700, 710, 711, 720 fields update rule for contributor name (section where target = "contributors.name") for the "type" property replace
"trim_period, trim"
value with"trim_punctuation"
value
before changes:
after changes:- Send PUT request to /mapping-rules/marc-bib and put in the body the updated JSON
Please note, that the array of the section for "720" field contains three "type" properties so the value for each of them should be updated.
"720": [ { "indicators": { "ind1": "1", "ind2": "*" }, "entity": [ { "target": "contributors.contributorNameTypeId", "description": "Type for Personal Name", "applyRulesOnConcatenatedData": true, "subfield": [], "rules": [ { "conditions": [ { "type": "set_contributor_name_type_id", "parameter": { "name": "Personal name" } } ] } ] }, { "target": "contributors.contributorTypeId", "description": "Type of contributor", "applyRulesOnConcatenatedData": true, "subfield": [ "4", "e" ], "rules": [ { "conditions": [ { "type": "set_contributor_type_id_by_code_or_name", "parameter": { "contributorCodeSubfield": "4", "contributorNameSubfield": "e" } } ] } ], "alternativeMapping": { "target": "contributors.contributorTypeText", "description": "Contributor type free text", "ignoreSubsequentSubfields": true, "subfield": [ "e" ] } }, { "target": "contributors.primary", "description": "Primary contributor", "applyRulesOnConcatenatedData": true, "subfield": [ ], "rules": [ { "conditions": [], "value": "false" } ] }, { "target": "contributors.name", "description": "Personal Name", "applyRulesOnConcatenatedData": true, "subfield": [ "a" ], "rules": [ { "conditions": [ { "type": "trim_punctuation" } ] } ] } ] }, { "indicators": { "ind1": " ", "ind2": "*" }, "entity": [ { "target": "contributors.contributorNameTypeId", "description": "Type for Personal Name", "applyRulesOnConcatenatedData": true, "subfield": [], "rules": [ { "conditions": [ { "type": "set_contributor_name_type_id", "parameter": { "name": "Personal name" } } ] } ] }, { "target": "contributors.contributorTypeId", "description": "Type of contributor", "applyRulesOnConcatenatedData": true, "subfield": [ "4", "e" ], "rules": [ { "conditions": [ { "type": "set_contributor_type_id_by_code_or_name", "parameter": { "contributorCodeSubfield": "4", "contributorNameSubfield": "e" } } ] } ], "alternativeMapping": { "target": "contributors.contributorTypeText", "description": "Contributor type free text", "ignoreSubsequentSubfields": true, "subfield": [ "e" ] } }, { "target": "contributors.primary", "description": "Primary contributor", "applyRulesOnConcatenatedData": true, "subfield": [ ], "rules": [ { "conditions": [], "value": "false" } ] }, { "target": "contributors.name", "description": "Personal Name", "applyRulesOnConcatenatedData": true, "subfield": [ "a" ], "rules": [ { "conditions": [ { "type": "trim_punctuation" } ] } ] } ] }, { "indicators": { "ind1": "2", "ind2": "*" }, "entity": [ { "target": "contributors.contributorNameTypeId", "description": "Type for Corporate Name", "applyRulesOnConcatenatedData": true, "subfield": [], "rules": [ { "conditions": [ { "type": "set_contributor_name_type_id", "parameter": { "name": "Corporate name" } } ] } ] }, { "target": "contributors.contributorTypeId", "description": "Type of contributor", "applyRulesOnConcatenatedData": true, "subfield": [ "4", "e" ], "rules": [ { "conditions": [ { "type": "set_contributor_type_id_by_code_or_name", "parameter": { "contributorCodeSubfield": "4", "contributorNameSubfield": "e" } } ] } ], "alternativeMapping": { "target": "contributors.contributorTypeText", "description": "Contributor type free text", "ignoreSubsequentSubfields": true, "subfield": [ "e" ] } }, { "target": "contributors.primary", "description": "Primary contributor", "applyRulesOnConcatenatedData": true, "subfield": [ ], "rules": [ { "conditions": [], "value": "false" } ] }, { "target": "contributors.name", "description": "Personal Name", "applyRulesOnConcatenatedData": true, "subfield": [ "a" ], "rules": [ { "conditions": [ { "type": "trim_punctuation" } ] } ] } ] } ]