SQLPASSTHRU MODE settings

<< Click to Display Table of Contents >>

Navigation:  »No topics above this level«

SQLPASSTHRU MODE settings

Return to chapter overview

This parameter determines whether and how passthrough SQL and standard BDE calls share the same database connections.  For transactions, this translates to whether passthrough transactions and other transactions “know” about each other.  

Only applications that use passthrough SQL need be concerned with SQLPASSTHRUMODE.  If you are developing an application to control transactions with passthrough SQL, you must set SQLPASSTHRU MODE to NOT SHARED.  Otherwise passthrough SQL and the application’s methods may interfere with each other, leading to unpredictable results.

Setting

Meaning

NOT SHARED

(blank setting) Passthrough SQL and non-passthrough SQL do NOT share the same database connection.

SHARED AUTOCOMMIT

Passthrough SQL and non-passthrough SQL will share the same connection, and (as long as you are not in an explicit client transaction or batch mode) passthrough SQL will be automatically committed.  Each operation on a single row is committed.  This mode most closely approximates desktop database behavior but it is inefficient on SQL servers because it starts and commits a new transaction for each row, resulting in a heavy load of network traffic.

SHARED NOAUTOCOMMIT

Passthrough SQL and non-passthrough SQL share the same connection, but passthrough statements will not be automatically committed.  The application must explicitly start and commit transactions. This setting could result in conflicts in busy multi-user environments where many users are updating the same rows.