Table 48. ADO, RDO, and MTS Sample Programs
Sample Program Name | Program Description |
---|---|
Bank.vbp | An RDO program to create and maintain data for bank branches, with the ability to perform transactions on customer accounts. The program can use any database specified by the user as it contains the DDL to create the necessary tables for the application to store data. |
Blob.vbp | This ADO program demonstrates retrieving BLOB data. It retrieves and displays pictures from the emp_photo table of the sample database. The program can also replace an image in the emp_photo table with one from a local file. |
BLOBAccess.dsw | This sample demonstrates highlighting ADO/Blob access using Microsoft
Visual C++. It is similar to the Visual Basic sample,
Blob.vbp. The BLOB sample has two main
functions:
|
Connect.vbp | This ADO program will create a connection object, and establish a connection, to the sample database. Once completed, the program will disconnect and exit. |
Commit.vbp | This application demonstrates the use of autocommit/manual-commit features of ADO. The program queries the EMPLOYEE table of the sample database for employee number and name. The user has an option of connecting to the database in either autocommit or manual-commit mode. In the autocommit mode, all of the changes that a user makes on a record are updated automatically in the database. In the manual-commit mode, the user needs to begin a transaction before he/she can make any changes. The changes made since the beginning of a transaction can be undone by performing a rollback. The changes can be saved permanently by committing the transaction. Exiting the program automatically rolls back the changes. |
db2com.vbp | This Visual Basic project demonstrates updating a database using the
Microsoft Transaction Server. It creates a server DLL used by the
client program, db2mts.vbp, and has four class
modules:
|
db2mts.vbp | This is a Visual Basic project for a client program that uses the Microsoft Transaction Server to call the server DLL created from db2com.vbp. |
Select-Update.vbp | This ADO program performs the same functions as Connect.vbp, but also provides a GUI interface. With this interface, the user can view, update, and delete data stored in the ORG table of the sample database. |
Sample.vbp | This Visual Basic project uses Keyset cursors via ADO to provide a graphical user interface to all data in the sample database. |
VarCHAR.dsp | A Visual C++ program that uses ADO to access VarChar data as textfields. It provides a graphical user interface to allow users to view and update data in the ORG table of the sample database. |