OAIP_getSupport
- Last Updated: May 12, 2026
- 4 minute read
- OpenAccess SDK
- Version 9.0
- Documentation
This function returns the requested information type in the buffer pInfoValue. This function is used by the OpenAccess SDK SQL engine to query the IP about its support for the types of SQL operations allowed, the mode in which the IP is working, whether DCL is supported, and other features.
The information reported by this function defines the mode in which the OpenAccess SDK SQL engine operates and how it interacts with the IP. It is called after OAIP_init, and may be called multiple times among other IP API calls.
int OAIP_getSupport(
IP_HDBC hdbc,
int iSupportType,
int * piSupportExists)
Parameters for OAIP_getSupport
| Parameter | Type | Description |
| IN | ||
| hdbc | IP_HDBC | The pointer to the connection data that you set up. |
| iSupportType | int | The type of support queried.See the table that follows for a list of IP support options. |
| piSupportExists | int * | A pointer to the flag to set TRUE if the support exists and FALSE if not. |
| RETURN | ||
| int | DAM_SUCCESS - on success DAM_FAILURE - on failure |
IP Support Options
| Support Option | Description |
| IP_SUPPORT_SELECT | The IP supports select. |
| IP_SUPPORT_INSERT | The IP supports insert. |
| IP_SUPPORT_UPDATE | The IP supports update. |
| IP_SUPPORT_DELETE | The IP supports delete. |
| IP_SUPPORT_SELECT_FOR_UPDATE | The IP supports select for update. |
| IP_SUPPORT_START_QUERY | The IP is to be notified of starting of query execution on the same table through multiple queries. |
| IP_SUPPORT_END_QUERY | The IP is to be notified of ending of query execution on the same table through multiple queries. |
| IP_SUPPORT_SCHEMA | The IP implements dynamic schema. |
| IP_SUPPORT_UNION_CONDLIST | The IP is to receive the condition lists as a union condition list. |
| IP_SUPPORT_PRIVILEGES | The IP implements a privilege function. |
| IP_SUPPORT_UNICODE_INFO | The IP is to use Unicode strings for owner name, owner term, qualifier, an qualifier term. |
| IP_SUPPORT_PUSHDOWN_QUERY | The IP will work in pass-through mode where it is responsible for executing the query. |
| IP_SUPPORT_TABLE_FUNCTIONS | The IP supports table functions. |
| IP_SUPPORT_NATIVE_COMMAND | The IP implements a NATIVE function that is called when the parser is unable to recognize the query. |
| IP_SUPPORT_BLOCK_JOIN | The IP has implemented block join optimization. |
| IP_SUPPORT_JOIN_ORDER_SELECTION | The IP supports the join order selection. |
| IP_SUPPORT_PASSTHROUGH_QUERY | The IP supports the PassThrough query. |
| IP_SUPPORT_QUERY_MODE_SELECTION | The IP determines at EXECUTE call whether to use pass-through query mode or row-based mode. |
| IP_SUPPORT_VALIDATE_SCHEMAOBJECTS_IN_USE | This option applies only when working in dynamic schema mode. Call the IP to return column information only for the columns referenced in the query. The SCHEMA function must be implemented to check for filter condition on the column name. |
| Operator Support | |
| IP_SUPPORT_OP_EQUAL | The IP can handle = conditions. |
| IP_SUPPORT_OP_NOT | The IP can handle NOT conditions. |
| IP_SUPPORT_OP_GREATER | The IP can handle > conditions. |
| IP_SUPPORT_OP_SMALLER | The IP can handle < conditions. |
| IP_SUPPORT_OP_BETWEEN | The IP can handle between conditions. |
| IP_SUPPORT_OP_LIKE | The IP can handle LIKE conditions. |
| IP_SUPPORT_OP_NULL | The IP can handle IS NULL condition. |
| DDL | SQL Data Definition Language support |
| IP_SUPPORT_CREATE_TABLE | The IP supports table creation. |
| IP_SUPPORT_DROP_TABLE | The IP supports table deletion. |
| IP_SUPPORT_CREATE_INDEX | The IP supports index creation. |
| IP_SUPPORT_DROP_INDEX | The IP supports index deletion. |
| IP_SUPPORT_ALTER_TABLE | The IP supports altering existing tables. |
| Stored Procedure | |
| IP_SUPPORT_PROCEDURE | The IP supports procedure execution. |
| Views | |
| IP_SUPPORT_CREATE_VIEW | The IP supports view creation. |
| IP_SUPPORT_DROP_VIEW | The IP supports view deletion. |
| IP_SUPPORT_QUERY_VIEW | The IP supports querying views. |
| SQL Data Control Language support (DCL) | |
| IP_SUPPORT_CREATE_USER | The IP supports the CREATE USER DCL command. |
| IP_SUPPORT_DROP_USER | The IP supports the DROP USER DCL command. |
| IP_SUPPORT_CREATE_ROLE | The IP supports the CREATE ROLE DCL command. |
| IP_SUPPORT_DROP_ROLE | The IP supports the DROP ROLE DCL command. |
| IP_SUPPORT_GRANT | The IP supports the GRANT DCL command. |
| IP_SUPPORT_REVOKE | The IP supports the REVOKE DCL command. |
The value for the IP_SUPPORT_OP_XX is the logical OR of the setting returned by this function and the setting in the OA_SUPPORT column of the OA_COLUMNS table for the specified column.
The value for the IP_SUPPORT_SELECT, IP_SUPPORT_INSERT, IP_SUPPORT_UPDATE, IP_SUPPORT_DELETE and IP_SUPPORT_SELECT_FOR_UPDATE is the logical OR of the setting returned by this function and the setting in the OA_SUPPORT column of the OA_TABLES table for the specified table name.
One way to implement this feature, and the template uses this approach, is to set up an array as shown in the following example, and to use the iSupportType as an index into it.
Example
const IP_SUPPORT_ARRAY xxx_support_array =
{0,
1, /* IP_SUPPORT_SELECT */
0, /* IP_SUPPORT_INSERT */
0, /* IP_SUPPORT_UPDATE */
0, /* IP_SUPPORT_DELETE */
1, /* IP_SUPPORT_SCHEMA */ /* value is controlled by ip_getSupport */
1, /* IP_SUPPORT_PRIVILEGES */
1, /* IP_SUPPORT_OP_EQUAL */
0, /* IP_SUPPORT_OP_NOT */
0, /* IP_SUPPORT_OP_GREATER */
0, /* IP_SUPPORT_OP_SMALLER */
0, /* IP_SUPPORT_OP_BETWEEN */
0, /* IP_SUPPORT_OP_LIKE */
0, /* IP_SUPPORT_OP_NULL */
0, /* IP_SUPPORT_SELECT_FOR_UPDATE */
0, /* IP_SUPPORT_START_QUERY */
0, /* IP_SUPPORT_END_QUERY */
0, /* IP_SUPPORT_UNION_CONDLIST */
1, /* IP_SUPPORT_CREATE_TABLE */
1, /* IP_SUPPORT_DROP_TABLE */
1, /* IP_SUPPORT_CREATE_INDEX */
1, /* IP_SUPPORT_DROP_INDEX */
1, /* IP_SUPPORT_PROCEDURE */
0, /* IP_SUPPORT_CREATE_VIEW */
0, /* IP_SUPPORT_DROP_VIEW */
0, /* IP_SUPPORT_QUERY_VIEW */
1, /* IP_SUPPORT_CREATE_USER */
1, /* IP_SUPPORT_DROP_USER */
1, /* IP_SUPPORT_CREATE_ROLE */
1, /* IP_SUPPORT_DROP_ROLE */
1, /* IP_SUPPORT_GRANT */
1, /* IP_SUPPORT_REVOKE */
0, /* IP_SUPPORT_PUSHDOWN_QUERY */
1, /* IP_SUPPORT_NATIVE_COMMAND */
1, /* IP_SUPPORT_ALTER_TABLE */
0, /* IP_SUPPORT_QUERY_MODE_SELECTION */
0, /* IP_SUPPORT_VALIDATE_SCHEMAOBJECTS_IN_USE */
0, /* IP_SUPPORT_UNICODE_INFO */
0, /* Reserved for future use */
0, /* Reserved for future use */
0, /* Reserved for future use */
0, /* Reserved for future use */
0, /* Reserved for future use */
0, /* Reserved for future use */
0, /* Reserved for future use */
0, /* Reserved for future use */
0, /* Reserved for future use */
0, /* Reserved for future use */
};