Automic STR_FIND Behavior: Eszett (ß) Character Matches 'ss' in v24+ Due to Unicode Case Folding
search cancel

Automic STR_FIND Behavior: Eszett (ß) Character Matches 'ss' in v24+ Due to Unicode Case Folding

book

Article ID: 411372

calendar_today

Updated On:

Products

CA Automic Workload Automation - Automation Engine

Issue/Introduction

After upgrading the Automic Windows Agent from version 21.x (C-based) to version 24.x (Java-based), the STR_FIND scripting function now returns an unexpected match when searching for the German character 'ß' (Eszett) in strings that contain 'ss' (double 's'). This differs from previous behavior in v21.x, where 'ß' and 'ss' were treated as distinct, leading to incorrect search results or script logic.

Symptoms:

  • Script Example:
    :S &Pfad# = 'C:\output'
    :S &Agent# = 'WIN01'
    :S &HND# = PREP_PROCESS_FILENAME(&AGENT#, &Pfad#, , , , 'UC_LOGIN=LOGIN.USETHIS')
    :PROCESS &HND# : S &LINE# = GET_PROCESS_LINE(&HND#)
    : IF STR_FIND(&LINE#, 'ß') > 0
    : P ß bei &LINE# Found! Abort, adjust file name!
    : EXIT 99
    : ENDIF
    :ENDPROCESS
    :P No errors found in the file name. Please adjust the file name!
  • Observation: In Automic v24.x, if a filename within C:\output contains "ss" (e.g., testss.txt), the STR_FIND function searching for 'ß' will unexpectedly return a positive match (position > 0), causing the script to exit with error 99. In version 21.x, testss.txt would not be considered a match for 'ß', and the script would execute as expected.

Environment

Product: CA Automic Workload Automation - Automation Engine

Version Affected: 24.x

OS: Windows (generally applicable to any OS where the agent runs)

Cause

This change in behavior is due to the introduction of Unicode and the concept of Case Folding in Automic Automation Engine 24.x.

  • In previous versions (v21), character comparison was typically based on single-byte representations (e.g., ASCII values), where 'ß' (hexadecimal 0xDF) and 'ss' were distinct sequences of characters.
  • In v24.x and later, the Automic Agent's string processing (including the STR_FIND function for caseless comparisons) now adheres to the Unicode standard for case folding. According to the Unicode specification (e.g., Unicode Case Folding Properties), the character 'ß' (LATIN SMALL LETTER SHARP S, U+00DF) is defined to fold to 'ss' (U+0073 U+0073) for caseless comparisons.
  • Since STR_FIND performs a caseless comparison, the observed behavior in v24.x is correct according to Unicode standards.

Resolution

The behavior where 'ß' matches 'ss' in STR_FIND (during caseless comparisons) is expected behavior in Automic Automation Engine 24.x and later versions due to adherence to modern Unicode standards. It is not considered a software defect.

Customers whose JCL scripts rely on a precise byte-level distinction between 'ß' and 'ss' when using STR_FIND must adjust their script logic to accommodate this Unicode behavior.

Additional Information

Workaround:
Implement additional conditional logic in JCL scripts to handle or explicitly exclude cases where 'ss' is matched when only 'ß' was intended. For example, after STR_FIND returns a positive result for 'ß', a secondary check could be added to confirm the exact character sequence if a strict 'ß' match is required.