Enables or disables autocommit. If autocommit is enabled, every SQL data manipulation statement is automatically committed. Otherwise, OraCommit function calls are necessary to commit SQL statements.
Ora.bdh
OraAutoCommit( in hConnection : number, in bAuto : boolean): boolean;
true if successful
false otherwise. In this case, you can use the OraOciError function to retrieve the Oracle OCI error code
Parameter | Description |
---|---|
hConnection | Handle to the database connection |
bAuto |
|
var hConnection: number; dcltrans transaction TMain var bOk: boolean; begin OraLogon(hConnection, "user", "password", "orclnet2"); bOk := OraAutoCommit(hConnection, true); if bOk thenwrite("Autocommit successfully set"); writeln; elsewrite("Autocommit could not be set"); writeln; end; OraLogoff(hConnection); end TMain;
Autocommit successfully set