|Oracle Objects for OLE C++ Class Library
Part Number A95896-01
The OSession object controls the behavior of an entire database session. You can access more than one database in a session. Typically an application has a single session, but applications can have more. A session is the unit on which transactions occur.
Please see Transactions for more complete information on transactions.
Database objects share the connection to the database if they are created on the same session (by using the same session as an argument in the ODatabase::Open method), and if they have the same connection information (database name, username, and password).
You can get OSession objects from OConnection, ODatabase, ODynaset, or OSessionCollection objects using the GetSession method.
Normally you will use the default session, for which you provide no name. You can also open sessions with specific names. Later you can get a list of sessions from the client object and identify sessions by name.
The OSession class supports the following methods:
Construction and destruction: