How is the database session obtained/maintained ?

How is the database session obtained/maintained ?

Postby Torben Nielsen » Mon 17 Aug 2009 09:29

How is the database session obtained/maintained using devart.

I want to obtain the following:

When an application start log onto the database
Today we call OCISessionBegin and then link the database session with our user table

This means that when executing stored procedures we have created a function
identifyUserAndGroup(l_userId, l_userName, l_groupId, l_groupName),
which is used to automatically fill out fields with who created, updated, owns various fields

Once the web request is over or the application stops OCISessionEnd is called.

How could the same functionality we obtained using devart, being able to
insure that all calls to Oracle is using the same underlying session.

What would be the correct approach?

Thanks in Advance
Torben Nielsen
Posts: 1
Joined: Mon 17 Aug 2009 09:26

Postby Shalex » Thu 20 Aug 2009 10:32

A separate session is created for each OracleConnection object. So we recommend you to disable pooling by setting Pooling=false; in your connection string, and to work with one connection object to be in the frame of one database session. You can also manage sessions using the OCI Session Pooling feature of the OracleConnection.ConnectionString property: , the Index tab, the ConnectionString Property (OracleConnection) section.
Devart Team
Posts: 7293
Joined: Thu 14 Aug 2008 12:44

Return to dotConnect for Oracle