IRepositoryODBC::get_ReposConnection
This method retrieves the ODBC connection handle that the repository engine is using to access the repository database.
HRESULT get_ReposConnection(long *pHdbc);
Parameters
*pHdbc
[out]
A copy of the repository engine ODBC connection handle.
Return Value
S_OK
The method completed successfully.
This method failed to complete successfully.
Remarks
If you use the repository engine ODBC connection handle, you are not isolated from changes made by the repository engine. For example, uncommitted changes made by the repository engine will be visible to your application.
When using the ODBC connection handle of the repository engine, you must not change the state of the handle in a way that is incompatible with the repository engine. Specifically, do not:
- Change any ODBC connection options.
- Perform any accesses concurrent with repository method invocations.
- Directly commit or roll back a database transaction. The IRepositoryTransaction interface must always be used to manage transactions.
Be sure to free the handle obtained through this method before releasing your open repository instance. To free the connection handle, use the FreeConnection method.