Skip to main content
It looks like you're using Internet Explorer 11 or older. This website works best with modern browsers such as the latest versions of Chrome, Firefox, Safari, and Edge. If you continue with this browser, you may see unexpected results.

University Library, University of Illinois at Urbana-Champaign

MarcEdit

An introduction to the MARC record editing software MarcEdit

Adding a Field

MarcEditor allows users to add a field either unilaterally or on the condition that certain fields are within the document. This is another instance where it is important to point out that the file that MarcEditor manipulates allows users to search the entire document, including fields. This is especially important because the syntax for applying the conditions will be dictated by how fields are added. For the purpose of clarity and uniformity, this method will repeat many steps from the above steps. For those interested in just adding a field regardless of conditions, apply the same steps used for adding fields conditionally without selecting the conditional statements. 

  1. Open the .mrk file by selecting it in the folder, which should open the file in MarcEditor, or open MarcEditor from the MarcEdit home screen and select the file in File->Open.
  2. Each datafield will be indicated by “=XXX” notation, which is fully searchable within MarcEditor.
  3. To add a datafield go to Tools► Add/Delete Field
  4. This will open the dialog box below:
  5. To conditionally add a field, select “Add field if Present/Not Present” from the Options menu. This will create an additional dialog box where you will put the condition required for adding the new field.
  6. Begin by entering the field you would like to add in the “Field” box or selecting it from the dropdown menu followed by the data you would like to add. If you want to add a subfield, simply put $[subfieldcode] before the string you would like inside the datafield, as below:
  7. In the “Find What” box, enter the string you want MarcEdit to search for in order to determine whether the field you entered in step 7 will be added. This is where the .mrk file becomes important. For example, if you want to add this field if and only if it has an 856 field, you would enter “=856” in the Find What box.
  8.  When you have entered this information, click “Add Field.” You will see a message indicating how many fields were added.
  9. If you want to undo this action, go to Edit►Special Undo 

Adding Field to a Batch of Records

MarcEdit allows users to add a datafield across a group of records both by adding it to all records or adding it only to records which do not currently have that datafield. Using this workflow, users will be prompted to enter the text for the new field.  This step also assumes that the batch of records have been converted from .mrc (MARC) to .mrk (Mnemonic MARC text file). To execute this process see Create MARC File for Editing in MARC Editor. This workflow will also require users to enter subfield and indicator data when adding the field, though more specific workflows exist for manipulating these areas directly: Editing Subfield Data, Edit Indicators.

 

  1. Open the .mrk file by selecting it in the folder, which should open the file in MarcEditor, or open MarcEditor from the MarcEdit home screen and select the file in File->Open.
  2. Each datafield will be indicated by “=XXX” notation, which is fully searchable within MarcEditor. This allows users to perform very specific functions using regular expressions, but it is worth remembering when searching the document.
  3. To add a datafield open the Tools section of the top menu and select add/delete fields, as below:

                                               

  1. This will open the dialog box below:

  1. Users can select the field they would like to add from a dropdown menu or key it in manually. Whatever information they would like entered into the field should be entered into the “Field Data” box, meaning that to add a, 049 with subfield a containing the text UIUU, the Field data box should read \\$aUIUU

When finished the dialog box should look like this:

 

  1. The options menu will configure which records will receive the datafield specified above and where it will be inserted. A table describing each of these functions as related to adding fields can be found below:

Option

Function Description

Match Case

Not used for adding fields

Use Regular Expressions Not used for adding fields
Process Batch Operation Copy Add/Delete tasks to task editor

Insert Before

When checked, the new field will be added in numerical order according to fields present within the record.

Insert Last

When checked, the new field will be appended to the end of the record

Add field only if not present

When checked, the new field will be added only if the record does not contain already that field

Add field only if not duplicate When checked, the new field will be added only if the record is not duplicate
Add field if Present / NOT Present When checked, the new field will be added if the record does not contain that field present or not contain that field

Remove Duplicate Data

Not used for adding fields

Remove by field position  Will delete field(s) by position; one can delete multiple fields positions by adding a comma to separate fields

Remove if field data does not match

Will delete fields where data entered in the “Field Data” box is not matched

These definitions apply only to fields being added, not operations where existing fields are replaced. In the example screenshot above, I have instructed MarcEdit to add a 500 Note field containing “Input Data” to all records which do not have a 500 field.

  1. After clicking “Add Field,” the MarcEdit will tell you how many records had the new field added.
  2. Examining the record in MarcEditor, you can see the field has been added:

You will also see that the record is added to the datafield with no subfield, if you would like to add input to a subfield within a datafield, put \\$[subfieldcode] before the string you would like inside the datafield. To add a specific indicator, substitute it for one of the slashes.

  1. If upon examination you find that the records you wanted changed do not have the fields desired, select Edit►Special Undo to reverse the transformation.

Deleting Field Within a Batch of Records

This function allows users to globally search a set of records and delete a particular field. It utilizes the same dialog box as adding fields, but since some options only apply to deleting fields in this dialog box they are present in separate workflows. This means that the first steps for this workflow are the same as those for adding a field. Regular expressions can be used to target particular data in a field, though this function is designed to mitigate the need to account for the way fields are represented in the .mrk format within a query within a regular expression.

  1. Open the .mrk file by selecting it in the folder, which should open the file in MarcEditor, or open MarcEditor from the MarcEdit home screen and select the file in File->Open.
  2. Each datafield will be indicated by “=XXX” notation, which is fully searchable within MarcEditor. This allows users to perform very specific functions using regular expressions, but it is worth remembering when searching the document.
  3. To add a datafield open the Tools section of the top menu and select add/delete fields, as below:

                                             

       This will open the dialog box below:

  1. Users can select the field they would like to delete from a dropdown menu or key it in manually. If you enter data into the “Field Data” box, MarcEdit will delete the fields specified by searching for the text in the box. If a field does not contain the text specified in the “Field Data” box, even if it is specified in the “Field” box, it will not be deleted. If you would like to delete the datafield regardless of its value in each record, specify the field number but leave “Field Data” blank.
  2. When you are finished, the dialog box should look something like this:


Here I have instructed MarcEdit to remove the 500 field if and only if it contains the string “Input Data.” If you would like to delete a field which contains data in a particular subfield, be sure to include it in the “Field Data.” For example, if I wanted to delete the 500 field if it contains Input Data in subfield a, I would enter “$aInput Data”. In this example, I have instructed it to match case. It is also possible to search using regular expressions.

  1.  When you are ready, click “Delete Field.” MarcEdit will tell you how many fields were deleted.
  2. If you find that the wrong records were altered or that you would like to undo the operation, select Edit►Special Undo.