The ooSQLiteConnection Class

An ooSQLiteConnection object represents a SQLite database, or to be more precise a connection to a SQLite database file. Each database in SQLite is contained in a single file. The files are platform independent, that is a database created and used on a Windows system can be moved to a Linux or Mac OS X system and will work unchanged.

Instantiating a connection object implicitly opens the SQLite database. SQLite supports multiple open connections to the same database. The Rexx programmer can open up multiple connections by instantiating multiple ooSQLiteConnection objects using the same database file name. The ooSQLite native extension builds the SQLite database engine in serialized multi-threading mode. In this mode the database engine can be safely used by multiple threads with no restriction. Therefore a connection object can be used in any thread in the Rexx program.

The close method should always be invoked when the connection object is no longer needed. This frees up the system resources used by the connection. The close method should be invoked even if an error ocurred during instantiation. Once close is invoked, the object can no longer be used to work with the database. It is an error to inovke database methods with a closed connection object. However, the close method can always be invoked. The method is a harmless nop if the connection has already been closed.