In UltraLite, the database does not have an ansi_substring option, but the SUBSTR function behaves as if ansi_substring is
set to on by default. The function's behavior corresponds to ANSI/ISO SQL/2008 behavior:
The first character in the string is at position 1. A negative or zero start offset is treated as if the string were
padded on the left with non-characters.
A positive length specifies that the substring ends length characters to the right of the starting position.
A negative length returns an error.
A length of zero returns an empty string.
If string-expression is of binary data type, the SUBSTRING function behaves as BYTE_SUBSTR.
To obtain characters at the end of a string, use the RIGHT function.
Whenever possible, if the input string uses character-length semantics, the return value is described in character-length
SUBSTRING is a core feature of the SQL/2008 standard. The standard's implementation differs slightly from the UltraLite
implementation: in the standard, SUBSTRING is defined with three parameters using the keywords FROM and FOR, neither of which
are required by UltraLite.