Skip to main content
ExLibris
  • Subscribe by RSS
  • ExLibris Dev

    Delete a subfield only when it has specific text in it using a batch job

    • Article Type: General
    • Product: Aleph
    • Product Version: 20

    Desired Outcome Goal:  


    How to delete field 630, subfield $$p only when it has text "O.T." in it?

     


    Procedure:  


    If this modification has to be done only once the easiest way would be the following:

    1. Select all records which have in 630$$p text "O.T." using "Retrieve Catalog Records (ret-01)"


    2. Use the output of 1. and create a file with all fields 630 using "Download Machine-Readable Records (print-03)"


    The output file then looks like this:
    000000014 63000 L $$aBible.$$pO.T.$$pPentateuch$$xCommentaries.
    000000015 63000 L $$aBible.$$pO.T.$$pPentateuch$$xCommentaries.
    000000021 63000 L $$aBible.$$pO.T.$$pGenesis$$xCommentaries.
    000000043 63000 L $$aBible.$$pO.T.$$pEzekiel$$vCommentaries.


    3. Open the output file and in the vi command line type ":1,$s/.$$pO.T././g". Result should be:


    000000014 63000 L $$aBible.$$pPentateuch$$xCommentaries.
    000000015 63000 L $$aBible.$$pPentateuch$$xCommentaries.
    000000021 63000 L $$aBible.$$pGenesis$$xCommentaries.
    000000043 63000 L $$aBible.$$pEzekiel$$vCommentaries.


    4. Reload the records using "Load ALEPH Sequential MARC Records (manage-18)" with the following parameters:


    - Procedure to run = Update current records in the database
    - If updating current records = Replace fields within a record


    This deletes subfield $$p when text "O.T." is in it.

     

     

    Additional Information:

     

    Another way of deleting a subfield with specific content is described in "Deletion of subfield with specific field content"

     

     

    Category: Cataloging (500) - ALEPH

    Subject: Services - ALEPH


    • Article last edited: 2/25/2014
    //doorbell.io feedback widged