ipSchema
- Last Updated: May 12, 2026
- 2 minute read
- OpenAccess SDK
- Version 8.1
- Documentation
You must implement this method in your IP if it is to handle schema management. The OpenAccess SDK SQL engine calls this method when it needs to get any of the following information about the schema:
- List of tables
- Columns for a table
- Details about each columns
- Foreign keys
- Indexes
- Other schema objects
If this method is implemented, the IP takes over the responsibility of exposing the OA_TABLES, OA_COLUMNS, OA_STATISTICS, OA_FKEYS, OA_PROC and OA_PROCCOLUMNS tables. The GETSUPPORT method should return true for IP_SUPPORT_SCHEMA. The implementation should use the search conditions that are passed in, and should cache any schema information that is time-consuming to retrieve.
int ipSchema(
long dam_hdbc,
long pMemTree,
int iType,
long pList,
Object pSearchObj)
Parameters for ipSchema
| Parameter | Type | Description |
| INPUT | ||
| dam_hdbc | long | The OpenAccess SDK SQL engine connection handle. |
| pMemTree | long | The memory tree to be used for all memory allocation. |
| iType | int | The type of schema information requested: |
| pList | long | Requested object(s) are returned by placing them in this list using the dam_add_schemaobj calls. The IP can pass the pSearchObj filter to the dam_add_schemaobj method to have the OpenAccess SDK SQL engine filter the objects before adding to the list. |
| pSearchObj | object | Contains the information about search conditions for the requested object type. The IP and the OpenAccess SDK SQL engine use this information to filter out the information returned by the IP. For example, if the OpenAccess SDK SQL engine needs only the columns for a specific table, it sets the table_name in the pSearchObj. The IP must use this information or pass the pSearchObj to the OpenAccess SDK SQL engine when calling the dam_add_schemaobj method. It is NULL if no search criteria is specified.For instance, if the user issues the query: SELECT * FROM oa_tables then pSearchObj is null and the IP returns all the table objects. Access this data by typecasting this pointer based on the requested object type (iType) and then accessing the members of the object to retrieve the required information: |
| RETURN | ||
| int | DAM_SUCCESS - on success DAM_FAILURE - on failure |
|