Skip to content

Main content

Marc Sub Field Code Split Tool

Split one display-form MARC subfield beginning with a literal dollar sign and one lowercase alphanumeric code.

Loading tool…

Description

Return that one-character code and all remaining text as value.

Catalog identifiers and labels follow local formatting conventions. Splitting or recognizing a token's shape preserves structure without establishing that its identifier or classification is valid.

Return that one-character code and all remaining text as value.

When to use this tool

Use Marc Sub Field Code Split when you need one explicit catalog-label parsing or formatting step.

How to use the tool and how it works

  1. Enter subfield. Use the units and conventions below.
  2. Run the tool. Correct any format, range, or cross-field input error before interpreting the output.
  3. Read code, value. Use the output convention below.

Require subfield to begin with dollar sign and a lowercase ASCII letter or digit. Return that one-character code and all remaining text as value.1

Input fieldMeaning and unitsAccepted input
subfieldSubfieldRequired. Text; maximum UTF-16 length 8192.
Output fieldInterpretationReturned shape
codeCodeRequired. Text; maximum UTF-16 length 8192.
valueNumeric value on the basis stated in the calculation above.Required. Text; maximum UTF-16 length 8192.
json
{
  "input": {
    "subfield": "$aThe title"
  },
  "output": {
    "code": "a",
    "value": "The title"
  }
}

Limitations and assumptions

  • An empty value is accepted; complete MARC syntax, separators inside values, field-specific validity, and source encoding are not checked.
  • Inputs must satisfy both the field types and the cross-field conditions above. Invalid input causes an error; a successful false flag or documented placeholder is a different result.

Alternative or Complementary methods

Consult the cataloging scheme and source record before assigning semantic meaning or a filing order.

References

  1. Calculation and input contract: library-science/marc-sub-field-code-split — tool.io

Similar or alternative tools