Click here to view and discuss this page in DocCommentXchange. In the future, you will be sent there automatically.

SQL Anywhere 11.0.1 » SQL Anywhere Server - Programming » SQL Anywhere Data Access APIs » SQL Anywhere embedded SQL » Using host variables » Indicator variables


Summary of indicator variable values

The following table provides a summary of indicator variable usage.

Indicator value Supplying value to database Receiving value from database
> 0 Host variable value Retrieved value was truncated—actual length in indicator variable
0 Host variable value Fetch successful, or conversion_error set to On
-1 NULL value NULL result
-2 NULL value Conversion error (when conversion_error is set to Off only). SQLCODE indicates a CANNOT_CONVERT warning
< -2 NULL value NULL result

For more information about retrieving long values, see GET DATA statement [ESQL].