sqlipGetParamspec
- Last Updated: May 12, 2026
- 1 minute read
- OpenAccess SDK
- Version 8.1
- Documentation
This method returns the description for the specified parameter. This method will be called m times where m is the number of parameters returned by the sqlipGetNumParams method.
int sqlipGetParamspec(
int iParmNum,
xo_int iXODataType,
xo_int piNullable,
xo_int piLen,
xo_int piPrecision,
xo_int piScale,
xo_int piDirection,
xo_int piFlags);
Parameters for sqlipGetParamspec
| Parameter | Type | Description |
| INPUT | ||
| iParam | int | Parameter number – first parameter starts at 1. |
| OUTPUT | ||
| iXODataType | xo_int | Data type of the parameter. |
| piNullable | xo_int | Whether the column can have null values. 1 – column can have null values 0 – the column cannot have null values |
| piLen | xo_int | Maximum length of the data in this column. Leave null for other types. CHAR and VARCHAR – maximum length of the string NUMERIC – precision + 2 |
| piPrecision | xo_int | Number of digits of mantissa precision. NUMERIC - Number of digits CHAR and VARCHAR - set to same as piLen INTEGER=10, SMALLINT=5, DOUBLE=15, REAL=7,FLOAT=15 DATE=10, TIME=8, TIMESTAMP=19 |
| piScale | xo_int | Total number of significant digits to the right of the decimal point. Only required for NUMERIC types |
| piDirection | xo_int | Direction of the parameter. SQL_PARAM_TYPE_UNKNOWN (0) SQL_PARAM_INPUT (1) SQL_PARAM_INPUT_OUTPUT (2) SQL_PARAM_OUTPUT (4) SQL_PARAM_RETURN_VALUE (5) |
| piFlags | xo_int | Not used |
| RETURN | ||
| int | OADS_SUCCESS OADS_ERROR |
Later, when a parameter value is sent to the third-party SQL engine IP layer from the client, the only information supplied is the actual data type of the parameter, its value, and the length of the value. The IP layer must perform the appropriate binding with the backend data source based on information it gathers and maintains during parameter description.