Substring(String: String From StartPosition: Number [For Length: Number]DH494)
Returns a substring of String, starting from StartPosition, with Length number of characters. If For Length is omitted, the substring goes from the StartPosition to the end of the String.
When applied to retrieved data of a SELECT statement, the effect is transient and does not affect stored data. When applied to the update atoms of an UPDATE statement, the effect is persistent and permanently converts the stored values.
Substring function syntax has these named arguments:
Parameter |
Description |
String |
Required. String to extract the substring from. |
StartPosition |
Required. The character to start the substring from. |
Length |
Optional. The number of characters for extract. |
For example:
Select Substring(CustomerName From 1 to 3) From ARCUST