About Transaction objects

In a PocketBuilder database connection, a Transaction object is a special nonvisual object that functions as the communications area between a PocketBuilder application and the database. The Transaction object specifies the parameters that PocketBuilder uses to connect to a database. You must establish the Transaction object before you can access the database from your application.

Communicating with the database

In order for a PocketBuilder application to display and manipulate data, the application must communicate with the database in which the data resides.

StepsTo communicate with the database from your PocketBuilder application:

  1. Assign the appropriate values to the Transaction object.

  2. Connect to the database.

  3. Assign the Transaction object to a DataWindow control or DataStore.

  4. Perform the database processing.

  5. Disconnect from the database.

For information about setting the Transaction object for a DataWindow control and using the DataWindow to retrieve and update data, see “Setting the transaction object for the DataWindow control”.

Default Transaction object

When you start executing an application, PocketBuilder creates a global default Transaction object named SQLCA (SQL Communications Area). You can use this default Transaction object in your application or define additional Transaction objects if your application has multiple database connections.

Transaction object properties

Each Transaction object has 15 properties, of which: