Wednesday, May 26, 2004

MARC Tools

Roy Zimmer has created and made available some Perl tools for working with MARC records. Thanks Roy.
  • Extracts BLOB data from Voyager. Pick one of the three data types, and specify the range of records to be retrieved. Output is human-formatted, unless you specify raw, and it goes to STDOUT (screen).
  • Count the MARC records in file filename. Output is to STDOUT (screen).
  • Add, remove, and/or edit fields in MARC records. Process inputfile to create outputfile. marcedit requires a marcedit.ini file (see below) in the local directory so that it knows what to do. You do not need to be a programmer to use marcedit, if the currently available functions fill your needs. Merely set up the directives in the .ini file, and run marcedit.
  • marcedit.ini This is the initialization file for (see above). You can create individualized copies of this file in different directories to meet your needs.
  • Read the MARC file indicated by filename. Output is human-formatted and goes to STDOUT (screen)
  • Splits file specified by infilename into chunks containing the number of lines specified by chunksize. An incrementing counter is appended to outfilename for each chunk so created. Example: abcin.this abcthis.out 100 This would create N files abcthis.out.1, abcthis.out.2, etc., each 100 lines in size, as many as necessary to divide abcin.this as specified

No comments: