Supported ODBC API Functions

This topic lists all the ODBC APIs (functions) supported by GemFire XD.

This document only provides a brief description of each supported API and any limitations with GemFire XD. For a full reference of ODBC APIs, please see the Microsoft ODBC Programmer's Reference.

If an ODBC API is not listed in this table, it is not supported by the GemFire XD ODBC driver.

Function API Summary Description and Link to API Reference Documentation Limitations and Known Issues with GemFire XD ODBC Driver
SQLAllocHandle Obtains an environment, connection, statement, or descriptor handle. See SQLAllocHandle Function. None.
SQLBindCol Binds application data buffers to columns in the result set. See SQLBindCol Function. None.
SQLBindParameter Binds a buffer to a parameter marker in an SQL statement. SQLBindParameter supports binding to a Unicode C data type, even if the underlying driver does not support Unicode data. See SQLBindParameter Function. None.
SQLBrowseConnect Unsupported by GemFire XD. See SQLBrowseConnect Function. This API is not supported in GemFire XD.
SQLBulkOperations Performs bulk insertions and bulk bookmark operations, including update, delete, and fetch by bookmark. See SQLBulkOperations Function. Bookmark is not supported. Only SQL_ADD is supported.
SQLCancel Unsupported by GemFire XD. Cancels the processing on a statement. See SQLCancel Function. This API is not supported in GemFire XD.
SQLCancelHandle Unsupported by GemFire XD. Cancels the processing on a connection or statement. See SQLCancelHandle Function. This API is not supported in GemFire XD.
SQLCloseCursor Closes a cursor that has been opened on a statement and discards pending results. See SQLCloseCursor Function. None.
SQLColAttribute Returns descriptor information for a column in a result set. Descriptor information is returned as a character string, a descriptor-dependent value, or an integer value. See SQLColAttribute Function. None.
SQLColAttributeW Same as SQLColAttribute but for wide chars. None.
SQLColumnPrivileges Returns a list of columns and associated privileges for the specified table. The driver returns the information as a result set on the specified StatementHandle. See SQLColumnPrivileges Function. With default permissions set on the table, no privilege data is retrieved. This API only retrieves privilege data if permissions are explicitly set on the table. Catalog API arguments must be in upper case.
SQLColumnPrivilegesW Same as SQLColumnPrivileges but for wide chars. Same as SQLColumnPrivileges.
SQLColumns Returns the list of column names in specified tables. The driver returns this information as a result set on the specified StatementHandle. See SQLColumns Function. None.
SQLColumnsW Same as SQLColumns but for wide chars. None.
SQLConnect Establishes connections to a driver and a data source. The connection handle references storage of all information about the connection to the data source, including status, transaction state, and error information. See SQLConnect Function. None.
SQLConnectW Same as SQLConnect but for wide chars. None.
SQLDescribeCol Returns the result descriptor-- column name, type, column size, decimal digits, and nullability-- for one column in the result set. This information is also available in the fields of the IRD. See SQLDescribeCol Function. None.
SQLDescribeColW Same as SQLDescribeCol but for wide chars. None.
SQLDescribeParam Returns the description of a parameter marker associated with a prepared SQL statement. This information is also available in the fields of the IPD. See SQLDescribeParam Function. None.
SQLDisconnect Closes the connection associated with a specific connection handle. See SQLDisconnect Function. None.
SQLDriverConnect SQLDriverConnect is an alternative to SQLConnect. It supports data sources that require more connection information than the three arguments in SQLConnect, dialog boxes to prompt the user for all connection information, and data sources that are not defined in the system information. See SQLDriverConnect Function. SQL_DRIVER_PROMPT is not supported. When using GemFire XD with either the unixODBC and iODBC driver managers, you cannot prompt the user for connection information with dialog boxes.
SQLDriverConnectW Same as SQLDriverConnect but for wide chars. None.
SQLEndTran Requests a commit or rollback operation for all active operations on all statements associated with a connection. SQLEndTran can also request that a commit or rollback operation be performed for all connections associated with an environment. See SQLEndTran Function. None.
SQLExecDirect Executes a preparable statement, using the current values of the parameter marker variables if any parameters exist in the statement. SQLExecDirect is the fastest way to submit an SQL statement for one-time execution. See SQLExecDirect Function. None.
SQLExecDirectW Same as SQLExecDirect but for wide chars. None.
SQLExecute Executes a prepared statement, using the current values of the parameter marker variables if any parameter markers exist in the statement. See SQLExecute Function. None.
SQLFetch Fetches the next rowset of data from the result set and returns data for all bound columns. See SQLFetch Function. None.
SQLFetchScroll Fetches the specified rowset of data from the result set and returns data for all bound columns. Rowsets can be specified at an absolute or relative position. See SQLFetchScroll Function. Bookmarks are not supported.
SQLForeignKeys Returns a list of foreign keys in the specified table (columns in the specified table that refer to primary keys in other tables.) A list of foreign keys in other tables that refer to the primary key in the specified table. See SQLForeignKeys Function. None.
SQLForeignKeysW Same as SQLForeignKeys but for wide chars. None.
SQLFreeHandle Frees resources associated with a specific environment, connection, statement, or descriptor handle. See SQLFreeHandle Function. None.
SQLFreeStmt Stops processing associated with a specific statement, closes any open cursors associated with the statement, discards pending results, or, optionally, frees all resources associated with the statement handle. See SQLFreeStmt Function. None.
SQLGetConnectAttr Returns the current setting of a connection attribute. See SQLGetConnectAttr Function. The following attributes are supported:
  • SQL_ATTR_CONNECTION_DEAD
  • SQL_ATTR_ACCESS_MODE
  • SQL_ATTR_AUTOCOMMIT
  • SQL_ATTR_CONNECTION_TIMEOUT
  • SQL_ATTR_METADATA_ID
  • SQL_ATTR_PACKET_SIZE
  • SQL_ATTR_TRANSLATE_OPTION
  • SQL_ATTR_LOGIN_TIMEOUT
  • SQL_ATTR_TXN_ISOLATION
  • SQL_ATTR_CURRENT_CATALOG
  • SQL_ATTR_TRANSLATE_LIB
  • SQL_ATTR_QUIET_MODE
SQLGetConnectAttrW Same as SQLGetConnectAttr but for wide chars. None.
SQLGetCursorName Returns the cursor name associated with a specified statement. See SQLGetCursorName Function None.
SQLGetCursorNameW Same as SQLGetCursorName but for wide chars. None.
SQLGetData Retrieves data for a single column in the result set or for a single parameter after SQLParamData returns SQL_PARAM_DATA_AVAILABLE. It can be called multiple times to retrieve variable-length data in parts. See SQLGetData Function. None.
SQLGetDiagField Returns the current value of a field of a record of the diagnostic data structure (associated with a specified handle) that contains error, warning, and status information. See SQLGetDiagField Function. There is limited GemFire XD support for this function. Diagnostics information is limited to the the following attributes:
  • SQL_DIAG_CURSOR_ROW_COUNT
  • SQL_DIAG_NUMBER
  • SQL_DIAG_ROW_COUNT
SQLGetDiagFieldW Same as SQLGetDiagField but for wide chars. Same limitations as SQLGetDiagField.
SQLGetDiagRec Returns the current values of multiple fields of a diagnostic record that contains error, warning, and status information. See SQLGetDiagRec Function. None.
SQLGetDiagRecW Same as SQLGetDiagRec but for wide chars. None.
SQLGetEnvAttr Returns the current setting of an environment attribute. See SQLGetEnvAttr Function. The following attributes are supported:
  • SQL_ATTR_ODBC_VERSION
  • SQL_ATTR_OUTPUT_NTS
SQLGetFunctions Returns information about whether a driver supports a specific ODBC function. See SQLGetFunctions Function. None.
SQLGetInfo Returns general information about the driver and data source associated with a connection. See SQLGetInfo Function. The following attributes are supported:
  • SQL_DRIVER_NAME
  • SQL_DRIVER_VER
  • SQL_DRIVER_ODBC_VER
  • SQL_ODBC_VER
  • SQL_MAX_DRIVER_CONNECTIONS
  • SQL_SCROLL_OPTIONS
  • SQL_DYNAMIC_CURSOR_ATTRIBUTES1
  • SQL_DYNAMIC_CURSOR_ATTRIBUTES2
  • SQL_STATIC_CURSOR_ATTRIBUTES1
  • SQL_STATIC_CURSOR_ATTRIBUTES2
  • SQL_BATCH_SUPPORT
  • SQL_BATCH_ROW_COUNT
  • SQL_PARAM_ARRAY_ROW_COUNTS
  • SQL_CURSOR_COMMIT_BEHAVIOR
  • SQL_EXPRESSIONS_IN_ORDERBY
  • SQL_GETDATA_EXTENSIONS
SQLGetStmtAttr Returns the current setting of a statement attribute. See SQLGetStmtAttr Function. The following attributes are supported:
  • SQL_ATTR_CONCURRENCY
  • SQL_ATTR_CURSOR_SCROLLABLE
  • SQL_ATTR_CURSOR_SENSITIVITY
  • SQL_ATTR_MAX_LENGTH
  • SQL_ATTR_MAX_ROWS
  • SQL_ATTR_ROW_ARRAY_SIZE
  • SQL_ATTR_ROW_BIND_TYPE
  • SQL_ATTR_ROW_STATUS_PTR
  • SQL_ATTR_ROWS_FETCHED_PTR
  • SQL_ATTR_ROW_BIND_OFFSET_PTR
  • SQL_ATTR_METADATA_ID
  • SQL_ATTR_NOSCAN
  • SQL_ATTR_PARAM_BIND_TYPE
  • SQL_ATTR_PARAMSET_SIZE
  • SQL_ATTR_PARAM_STATUS_PTR
  • SQL_ATTR_PARAMS_PROCESSED_PTR
  • SQL_ATTR_QUERY_TIMEOUT
  • SQL_ATTR_KEYSET_SIZE
  • SQL_ATTR_PARAM_BIND_OFFSET_PTR
  • SQL_ATTR_PARAM_OPERATION_PTR
  • SQL_ATTR_ROW_OPERATION_PTR
The following Descriptor attributes are not supported. The driver will return only placeholder values for them:
  • SQL_ATTR_APP_ROW_DESC
  • SQL_ATTR_IMP_ROW_DESC
  • SQL_ATTR_APP_PARAM_DESC
  • SQL_ATTR_IMP_PARAM_DESC
SQLGetStmtAttrW Same as SQLGetStmtAttr but for wide chars. None.
SQLGetTypeInfo Returns information about data types supported by the data source. The driver returns the information in the form of an SQL result set. The data types are intended for use in Data Definition Language (DDL) statements. None.
SQLGetTypeInfoW Same as SQLGetTypeInfo but for wide chars. See SQLGetTypeInfo Function. None.
SQLMoreResults Determines whether more results are available on a statement. See SQLMoreResults Function. Explicit batches are not supported. Use stored procedures instead. Affected row count must be retrieved using select count(*) alternative and is applicable for only insert and update operations.
SQLNativeSql Returns the SQL string as modified by the driver. SQLNativeSql does not execute the SQL statement. See SQLNativeSql Function. None.
SQLNativeSqlW Same as SQLNativeSql but for wide chars. None.
SQLNumParams Returns the number of parameters in an SQL statement. See SQLNumParams Function. None.
SQLNumResultCols Returns the number of columns in a result set. See SQLNumResultsCols Function. None.
SQLParamData Used together with SQLPutData to supply parameter data at statement execution time, and with SQLGetData to retrieve streamed output parameter data. See SQLParamData Function. None.
SQLPrepare Prepares an SQL string for execution. See SQLPrepare Function. None.
SQLPrepareW Same as SQLPrepare but for wide chars. None.
SQLPrimaryKeys Returns the column names that make up the primary key for a table. The driver returns the information as a result set. This function does not support returning primary keys from multiple tables in a single call. See SQLPrimaryKeys Function. None.
SQLPrimaryKeysW Same as SQLPrimaryKeys but for wide chars. None.
SQLProcedureColumns Returns the list of input and output parameters, as well as the columns that make up the result set for the specified procedures. The driver returns the information as a result set on the specified statement. See SQLProcedureColumns Function. None.
SQLProcedureColumnsW Same as SQLProcedureColumns but for wide chars. None.
SQLProcedures Returns the list of procedure names stored in a specific data source. See SQLProcedures Function. None.
SQLProceduresW Same as SQLProcedures but for wide chars. None.
SQLPutData Allows an application to send data for a parameter or column to the driver at statement execution time. See SQLPutData Function. None.
SQLRowCount Returns the number of rows affected by an UPDATE, INSERT, or DELETE statement. See SQLRowCount Function. Bookmark is not supported.
SQLSetConnectAttr Sets attributes that govern aspects of connections. See SQLSetConnectAttr Function. The following attributes are supported:
  • SQL_ATTR_ACCESS_MODE
  • SQL_ATTR_AUTOCOMMIT
  • SQL_ATTR_CONNECTION_TIMEOUT
  • SQL_ATTR_METADATA_ID
  • SQL_ATTR_PACKET_SIZE
  • SQL_ATTR_TRANSLATE_OPTION
  • SQL_ATTR_TXN_ISOLATION
  • SQL_ATTR_LOGIN_TIMEOUT
  • SQL_ATTR_QUIET_MODE
  • SQL_ATTR_CURRENT_CATALOG
  • SQL_ATTR_TRANSLATE_LIB
SQLSetConnectAttrW Same as SQLSetConnectAttr but for wide chars. Same as SQLSetConnectAttr.
SQLSetCursorName Associates a cursor name with an active statement. See SQLSetCursorName Function. None.
SQLSetCursorNameW Same as SQLSetCursorName but for wide chars. None.
SQLSetEnvAttr Sets attributes that govern aspects of environments. See SQLSetEnvAttr Function. The following attributes are supported:
  • SQL_ATTR_ODBC_VERSION
  • SQL_ATTR_OUTPUT_NTS
  • SQL_ATTR_ANSI_APP
SQLSetPos Sets the cursor position in a rowset and allows an application to refresh data in the rowset or to update or delete data in the result set. See SQLSetPos Function. Only SQL_POSITION operation is supported.
SQLSetStmtAttr Sets attributes related to a statement. See SQLSetStmtAttr Function.
  • SQL_ATTR_CONCURRENCY
  • SQL_ATTR_CURSOR_SCROLLABLE
  • SQL_ATTR_CURSOR_SENSITIVITY
  • SQL_ATTR_CURSOR_TYPE
  • SQL_ATTR_MAX_LENGTH
  • SQL_ATTR_MAX_ROWS
  • SQL_ATTR_METADATA_ID
  • SQL_ATTR_ROW_ARRAY_SIZE
  • SQL_ATTR_ROW_BIND_TYPE
  • SQL_ATTR_ROW_STATUS_PTR
  • SQL_ATTR_ROWS_FETCHED_PTR
  • SQL_ATTR_ROW_BIND_OFFSET_PTR
  • SQL_ATTR_NOSCAN
  • SQL_ATTR_PARAM_BIND_TYPE
  • SQL_ATTR_PARAMSET_SIZE
  • SQL_ATTR_PARAM_STATUS_PTR
  • SQL_ATTR_PARAMS_PROCESSED_PTR
  • SQL_ATTR_QUERY_TIMEOUT
  • SQL_ATTR_KEYSET_SIZE
  • SQL_ATTR_PARAM_BIND_OFFSET_PTR
  • SQL_ATTR_PARAM_OPERATION_PTR
  • SQL_ATTR_ROW_OPERATION_PTR
SQLSetStmtAttrW Same as SQLSetStmtAttr but for wide chars. Same as SQLSetStmtAttr.
SQLSpecialColumns Retrieves the following information about columns within a specified table: The optimal set of columns that uniquely identifies a row in the table. Columns that are automatically updated when any value in the row is updated by a transaction. See SQLSpecialColumns Function. The IdentifierType SQL_ROWVER is not supported. Catalog API arguments must be in upper case.
SQLStatistics Retrieves a list of statistics about a single table and the indexes associated with the table. The driver returns the information as a result set. See SQLStatistics Function. None.
SQLStatisticsW Same as SQLStatistics but for wide chars. None.
SQLTablePrivileges Returns a list of tables and the privileges associated with each table. The driver returns the information as a result set on the specified statement. See SQLTablePrivilges Function. With default permissions set on the table, no privilege data is retrieved. This API only retrieves privilege data if permissions are explicitly set on the table. Catalog API arguments must be in upper case.
SQLTablePrivilegesW Same as SQLTablePrivileges but for wide chars. Same as SQLTablePrivileges.
SQLTables Returns the list of table, catalog, or schema names, and table types, stored in a specific data source. The driver returns the information as a result set. See SQLTables Function. None.
SQLTablesW Same as SQLTables but for wide chars. None.

Additional API Attribute Limitations with the ODBC Driver and ODBC Driver Managers

The following table describes additional ODBC driver limitations:
  • SQL_C_BIT, SQL_C_STINYINT, SQL_C_UTINYINT. Bit and Tinyint data types are not supported.
  • SQL_ATTR_TRACE_ON, SQL_ATTR_TRACE_OFF attributes are not supported by the iODBC driver.
  • SQL_ATTR_LOGIN_TIMEOUT. This attribute corresponds to the number of seconds to wait for a login request to complete before returning to the application. For this attribute, iODBC driver manager returns an indicator value of 0. The unixODBC driver manager returns an indicator of 4.
  • SQL_ATTR_PACKET_SIZE. Connection attribute for setting connection packet size. Setting packet size is not supported by the driver.
  • SQL_ATTR_AUTO_IPD, SQL_ATTR_ENABLE_AUTO_IPD. Attributes related to automatic population of IPD. Driver does not support these attributes.
  • SQL_ATTR_METADATA_ID. This attribute determines how the string arguments of catalog funcitons are treated. This attribute is applicable for connection and statement handles. Only the SQL_FALSE option is supported.