ASA SQL Reference
SQL Functions
Alphabetical list of functions
This function returns a string that identifies the data type of an expression.
EXPRTYPE ( string-expression, integer-expression )
string-expression A SELECT statement. The expression whose data type is to be queried must appear in the select list. If the string is not a valid SELECT statement, NULL is returned.
integer-expression The position in the select list of the desired expression. The first item in the select list is numbered 1. If the integer-expression value odes not correspond to a SELECT list item, NULL is returned.
SQL/92 Vendor extension.
SQL/99 Vendor extension.
Sybase Not supported in Adaptive Server Enterprise.
The following statement returns smallint
when executed against the sample database.
SELECT EXPRTYPE( 'SELECT line_id FROM sales_order_items', 1 )