Using a Phrase Separator for File-based Recode Tables - trillium_discovery - trillium_quality - 17.2

Trillium Control Center

Product type
Software
Portfolio
Verify
Product family
Trillium
Product
Trillium > Trillium Discovery
Trillium > Trillium Quality
Version
17.2
Language
English
Product name
Trillium Quality and Discovery
Title
Trillium Control Center
First publish date
2008
Last updated
2024-07-01
Published on
2024-07-01T08:56:48.630530

The default operation of table recoding requires the entire attribute to match the entry in the recode table. For example, if the recode table is specified to change 'World' to 'Y,' and the input data is "Hello World, " recoding will not be performed because the entire attribute (Hello World) does not match the table entry (World) even though it contains the string 'World.'

If you want to look-up part of the attribute, use the Phrase Separator option in the Table Recode window. The Phrase Separator option allows you not only to select portion of the attribute, but also control the separator characters and other variations.

Note: The phrase separator option is available only for the literal type.

To use the phrase separator option

  1. In the Table Recode window, check Use phrase separator and select or specify the following options:

    Option

    Description

    Example

    Any

    Any character including a space can be a separator.

    Recode Table: World, Y

    Input Data: Hello World

    Result: Hello Y

    The result is "Hello Y" because 'World' is found in the input data and the space is used as a separator.

    None Use no separators. The entire attribute is required to match the entry in the recode table.

    Recode Table: World, Y

    Input Data: Hello World

    Result: Hello World

    The recoding will not be performed because the entire attribute (Hello World) does not match the table entry (World).

    Explicit

    Specify any character or a list of characters that are used to separate the string in the attribute.

    Example: / .,?"$<>

    Recode Table: World, Y

    Input Data: Hello/World

    Explicit: /

    Result: Hello Y

    The result is "Hello Y" because 'World' is found in the input data and the backslash (/) is used as a separator.

    Look-up Position

    Select a position of the phrase separator.

    • Beginning of phrase
    • End of phrase
    • Anywhere in phrase

    Recode Table: World, Y

    Input Data: Hello World/

    Look-up position: End of phrase

    Result: Hello Y

    The result is "Hello Y" because 'World' is found in the input data and the separator (/) is found at end of the phrase.

    Phrase Recode Only

    Recode only the look-up value itself, not the entire attribute. This option is selected by default. When this option is not selected, the entire attribute will be recoded. This option is typically used to set a flag in a different attribute whenever a specified value is found in the input data.

    Note: This operation is subject to the previous options such as the explicit separator and look-up position.

    Recode Table: World, Y

    Input Data: Hello World

    Separator: Any

     

    Phrase Recode Only: ON (default)

    Result: Hello Y

    The result is 'Hello Y' because 'World' is found in the input data, the space is used as a separator, and the matching string (World) is recoded to 'Y.'

     

    Phrase Recode Only: OFF

    Result: Y

    The result is 'Y' because 'World' is found in the input data, the space is used as a separator, and the entire attribute is recoded to 'Y.'

  2. Click Next to specify the match attributes and recode attributes.