Parse options

TParseOptions is a set of TParseOption flags given to ParseInput to control the processing after the input is split into tokens. The default is [] (no options).

Option Applies to Effect
opTrim all types Removes leading and trailing spaces from the input and from each token.
opNotNull all types Rejects any token that became NULL: ERR_NULL_NOT_ALLOWED.
opRequired all types Rejects empty input: ERR_EMPTY_NOT_ALLOWED.
opEmptyStringNull itString Empty tokens give NULL instead of ''.
opUpperCase itString Converts the values to upper case.
opLowerCase itString Converts the values to lower case.

Processing order

  1. opTrim (when set): applied to the whole input.
  2. opRequired: checked against the (possibly trimmed) input; stops with ERR_EMPTY_NOT_ALLOWED when it is empty.
  3. Tokenization: the input is split into tokens.
  4. Each token: type parsing, opTrim on the token, opEmptyStringNull, opUpperCase / opLowerCase.
  5. opNotNull: checked after all the tokens; stops with ERR_NULL_NOT_ALLOWED when an entry of SQLValues is NULL.
  6. Range order check: after opNotNull.
R := ParseInput(Edit1.Text, itString, [opTrim, opRequired, opUpperCase]);

See Also

(C) 2026 Easygate, Lda