Skip to content

Script to update OCLC numbers in Alma records based on MARC merge files from OCLC's WorldShare Collection Manager

License

Notifications You must be signed in to change notification settings

frenchrb/update_OCNs_ongoing

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 

Repository files navigation

update_OCNs_ongoing

Script to update OCLC numbers in Alma records based on MARC merge files from OCLC's WorldShare Collection Manager

Searches Alma for records matching the OCNs found in the input file's 019 fields, then changes 035 (OCoLC) in any records found to the current OCN from the input file's 035 subfield a. Also changes any e-book unique identifiers in 035 fields with the prefix (ViHarT-EM) to use the new OCN. Output spreadsheet shows all matching records found on the first tab and all changes made on the second tab.

Requirements

Created and tested with Python 3.7; see environment.yml for complete requirements.

Requires an Alma Bibs API key with read/write permissions. A config file (local_settings.ini) with this key should be located in the same directory as the script and input file. To switch between production and sandbox environments, provide both API keys in local_settings.ini and comment out the appropriate lines 23/24 and 199/200 in the script.

Example of local_settings.ini:

[Alma Production Bibs R/W]
key:apikey

[Alma Sandbox Bibs R/W]
key:apikey

Usage

python update_OCNs_ongoing.py input.mrc where input.mrc is a MARC merge file from OCLC's WorldShare Collection Manager, where each record has previous OCNs in the 019 field and the desired new OCN in 035 subfield a.

Contact

Rebecca B. French - https://github.com/frenchrb

About

Script to update OCLC numbers in Alma records based on MARC merge files from OCLC's WorldShare Collection Manager

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages