Skip to main content
Administrator Guide
Last Updated: 2024-05-17
Substring Text

Substring Text

Security:
Custom Field Management
domain in the System functional area.
You can use the calculated field to extract a portion of text from a single instance or text field and return the result as a text field.
  1. Access the
    Create Calculated Field
    task.
  2. Select
    Substring Text
    for the
    Function
    .
  3. On the
    Calculation
    tab, select a single instance or text field for the
    Text Field
    .
    If you select a single instance field, Workday uses the display ID value of the field.
  4. Select the
    Substring Type
    .
    In the
    Fixed Position
    , the first character in the field holds position 1, the second character holds position 2, and so on. You can specify the length of the substring to extract with these options:
    Option Description
    Fixed Length
    The length of the substring starts at the specified
    Starting Character Position
    and continues for the specified length of characters. The substring value returns shortened or padded with spaces if:
    • The
      Starting Character Position
      is greater than the length of the text field.
    • The text field doesn't have enough characters to return a substring with a length equal to the fixed length specified.
    Until End of Text Field
    The length of the substring returned varies. The substring starts at the specified
    Starting Character Position
    and continues to the end of the field.
  5. (Optional) For the
    Between two Delimiters
    Substring Type
    , select the
    Exclude Results without End Delimiters
    check box to exclude field results without an end delimiter and display a blank value. Clear the check box to return all field results, including results without an end delimiter.
  6. Select the
    Remove Leading and Trailing Spaces
    check box to remove spaces at the beginning and end of the substring.
    Example: If you have "A B C D " as the original string, you can select 2 as the start position and 5 characters as the fixed length. The substring is " B C " since spaces count as characters. The result is "B C" because Workday automatically removes leading and trailing spaces from the substring.
  7. (Optional) In the
    Advanced
    section on the
    Additional Info
    tab, select the
    Do not use Alternate Display ID
    check box from the
    Options
    prompt.
    Instead of using the alternate display ID, Workday uses the display ID from the text source for substring text extraction.
After a Delimiter (Forward Direction)
After a Delimiter
Original String
Substring Result
"-"
"ABC-XYZ"
"XYZ"
"BC"
"ABC-XYZ"
"-XYZ"
"W"
"ABC-XYZ"
""
"/"
"07/04"
"04"
After a Delimiter (Backward Direction)
After a Delimiter
Original String
Substring Result
"-"
"ABC-XYZ"
"XYZ"
" "
"Senior Clerk (Pleasanton)"
"(Pleasanton)"
" "
"Accounting 6373"
"6373"
" "
"Sales and Marketing 7283"
"7283"
Before a Delimiter (Forward Direction)
Before a Delimiter
Original String
Substring Result
"-"
"ABC-XYZ"
"ABC"
"BC"
"ABC-XYZ"
"A"
"W"
"ABC-XYZ"
""
"/"
"07/04"
"07"
Between Two Delimiters
Start Delimiter
End Delimiter
Original String
Substring Result
"["
"]"
"ABC-[XYZ]"
"XYZ"
"("
")"
"Logan McNeil (41600 HR Services)"
"41600 HR Services"
Fixed Position (Until the End of the Text Field)
Starting Character Position
Original String
Substring Result
2
"Senior Clerk"
"enior Clerk"
8
"Senior Clerk"
"Clerk"
13
"Senior Clerk"
""
Fixed Position (Fixed Length)
Starting Character Position
Fixed Length
Original String
Substring Result
2
5
"Senior Clerk"
"enior"
8
5
"Senior Clerk"
"Clerk"
8
3
"Senior Clerk"
"Cle"
8
10
"Senior Clerk"
"Clerk "
13
4
"Senior Clerk"
" " (4 spaces)
  • Create additional calculated fields.
  • Create new calculated fields from within a substring text calculated field.