KI_SQL
Argument | Enumeration | Purpose |
---|---|---|
handle | Handle | |
sql$ | SQL statement | |
extratext$ | Extra SQL | |
status | KDB_ERROR_ENUM | Return status |
colcount | Number of columns in result set |
KI_SQL
This combines KI_PREPARE and KI_EXECUTE into one function for convenience and to make it possible to recover following a database server failure. You should only use these functions separately if you need to invoke KI_EXECUTE multiple times for a single KI_PREPARE. Combining the two functions make it possible for KCML to replay both transparently if a database failure is detected.
The number of columns in any result set is returned in the optional colcount which will be zero if there is no result set, as in a DELETE or UPDATE.
If a negative handle number is passed then only SELECT statements can be parsed as a security measure.
On Oracle and Postgres the optional extratext$ parameter will be appended to CREATE TABLE and CREATE INDEX statements, after any default storage and tablespace clauses, to allow custom partitioning schemes to be deployed.
Compatibility
Prior to KCML 6.40 the function now called KI_SQL_XML was named KI_SQL.