Skip to content

Main content

HL7 Repeat Escape Unescape One Token Tool

Decode one HL7 v2 named delimiter escape using explicit distinct delimiters; hex, formatting and local escapes are outside this token operation.

Loading tool…

Description

Decode F, S, R, T, or E as field, component, repetition, subcomponent, or escape delimiter.

Clinical exchange formats use exact delimiters, character grammars, and scoped identifiers. A local token check addresses one syntax condition and can succeed without validating a complete message or its clinical meaning.

Decode F, S, R, T, or E as field, component, repetition, subcomponent, or escape delimiter.

When to use this tool

Use HL7 Repeat Escape Unescape One Token when you need one bounded spelling, delimiter, or identifier component.

How to use the tool and how it works

  1. Enter token, fieldSeparator, componentSeparator, repetitionSeparator, escapeCharacter, subcomponentSeparator. 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 decoded, kind. Use the output convention below.

Require five distinct one-UTF-16-unit delimiters and a three-unit escape token using the supplied escape character. Decode F, S, R, T, or E as field, component, repetition, subcomponent, or escape delimiter.1

Input fieldMeaning and unitsAccepted input
tokenText in the explicitly supported lexical grammar.Required. Text; maximum UTF-16 length 8192.
fieldSeparatorField SeparatorRequired. Text; maximum UTF-16 length 8192.
componentSeparatorComponent SeparatorRequired. Text; maximum UTF-16 length 8192.
repetitionSeparatorRepetition SeparatorRequired. Text; maximum UTF-16 length 8192.
escapeCharacterEscape CharacterRequired. Text; maximum UTF-16 length 8192.
subcomponentSeparatorSubcomponent SeparatorRequired. Text; maximum UTF-16 length 8192.
Output fieldInterpretationReturned shape
decodedDecodedRequired. Text; maximum UTF-16 length 8192.
kindKindRequired. Text; maximum UTF-16 length 8192.
json
{
  "input": {
    "token": "\\R\\",
    "fieldSeparator": "|",
    "componentSeparator": "^",
    "repetitionSeparator": "~",
    "escapeCharacter": "\\",
    "subcomponentSeparator": "&"
  },
  "output": {
    "decoded": "~",
    "kind": "repetition"
  }
}

Limitations and assumptions

  • Only one delimiter escape token is decoded; hexadecimal, formatting, local escapes, complete messages, and clinical semantics are not handled.
  • 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

Use the relevant full standard, implementation profile, and validated parser when interoperable or clinical record validity matters.

References

  1. Calculation and input contract: health-informatics/hl7-repeat-escape-unescape-one-token — tool.io

Similar or alternative tools

  • HL7 Component Escape Gap

    Toggle escape state at each escape delimiter, count completed pairs, count separators outside pairs, and report unclosedEscape.

  • HL7 Delimiter Role Label

    Map the concatenated order to field, component, repetition, escape, subcomponent, and optional truncation roles.