Using a String Field

About this task

A string field contains one or more printable characters. If you specify that a field is a string field, you must also specify the format of the string by assigning a syntax token. A syntax token is a data sub-type that applies only to string fields and can contain of one or more character ranges and single characters, such as $, Q, or @. A character range is a pair of characters that define the start and end characters of the range. The Sterling B2B Integrator Map Editor provides several syntax tokens, including syntax token K, which includes all Japanese double-byte characters and excludes single-byte characters. The Sterling B2B Integrator Map Editor also provides a Free Format option, which indicates that any characters are acceptable in the field, and the translator does not check the characters for compliance. You can also create special syntax tokens to meet your specific needs.

You assign a syntax token to a field to check the field for compliance during translation. For example, if a field with syntax token A assigned to it (character range A through Z and a through z) contains a number, the translator generates a compliance error. You specify that a field is a string and assign a syntax token in the Field, Element, or TFD Properties dialog box, on the Validation tab, in the data format field.

To specify a string field:

Procedure

  1. In the Sterling B2B Integrator Map Editor, double-click an existing field or create a new one.

    For more information about creating fields, see Add Map Components.

  2. In the appropriate Properties dialog box, click the Validation tab.
  3. From the data-type list, select String.
  4. From the data format list, select Free Format or the appropriate syntax token.

    Free Format indicates that any characters are acceptable in the field. The translator does not check the characters for compliance.

    If you select Free Format, the drop-down list becomes an editable text box. Free Format indicates that any characters are acceptable in the field. The translator does not check the characters for compliance.

  5. In the text box, type the appropriate characters for this field.
  6. Click OK to save your selections.