skip to main content
Designing and coding the IP : DDL object management : Drop Index processing
 

Drop Index processing

The SQL syntax to drop an index is:
DROP INDEX index-name;
When a SQL query of this form is issued, OpenAccess SDK SQL engine maps this information to a list of schema objects of type damobj_stat. When the DDL function in the IP is called, the DDL function should perform the following steps:
1. Obtain information about the index (table name, table owner, table qualifier, index name).
pList = dam_getSchemaObjectList(hstmt, DAMOBJ_TYPE_STAT);
damobj_stat pStatObj = getFirstSchemaObject(pList);
2. Use this information to drop the index.