cci_savepoint

Description

The cci_savepoint function configures savepoint or performs transaction rollback to a specified savepoint. If cmd is set to CCI_SP_SET, it configures savepoint and if it is set to CCI_SP_ROLLBACK, it rolls back transaction to specified savepoint.

Syntax

intcci_savepoint(int conn_handle, T_CCI_SAVEPOINT_CMD cmd, char* savepoint_name, T_CCI_ERROR *err_buf)

Return Value
Example

con = cci_connect( ...);

.../* query execute */

 

/* sets a savepoint named "savepoint1"

cci_savepoint(con, CCI_SP_SET, "savepoint1", err_buf);

 

... /* query execute */

 

/* rolls back the set savepoint to "savepoint1" */

cci_savepoint(con, CCI_SP_ROLLBACK, "savepoint1", err_buf);