LEFT
LEFT returns the first character or characters in a text string, based on the number of characters you specify.
Use
LEFT( text, [num_chars] )
Returns the leftmost characters from a text value.
Argument | Required | Description |
---|---|---|
text | Yes | The text string that contains the characters you want to extract. |
num_chars | No | Specifies the number of characters you want LEFT to extract. Must be greater than or equal to zero. If greater than the length of text, returns all of text. If omitted, assumed to be 1. |
Returns | 'Text' |
Use with literals
LEFT("Hello")
returns "H"
LEFT("Hello", 4)
returns "Hell"
Use with fields
LEFT(@LocateCustomer.out.Forename, 3)
returns "Ben" where field @LocateCustomer.out.Forename is "Benjamin"