Public Methods | |
Connection () | |
Connection (OCIEnv *env, const string &tnsname, const string &user, const string &password) | |
~Connection () | |
void | drop () |
void | init (OCIEnv *env, const string &tnsname, const string &user, const string &password) |
Cursor* | execQuery (const string &) |
void | execQuery (const string &,Cursor &,int prefetch=1) |
void | execUpdate (const string &) |
void | transStart (int flags=SERIALIZABLE) |
void | transCommit () |
void | transRollback () |
void | prepare (const string &sql, Cursor &cur, int prefetch=1) |
void | getQueue (string &queue_name, OCICPP::AQQueue &queue) |
void | createBFile (const string &,const string &,BFile &) |
void | createTLob (int lobtype, int cachemode, TLob &) |
string | serverVersion () |
By creating a connection to a database, a programm can interact with a database instance by the access right associated to the connection.
A connection can be initialized by db::connect()
|
Default constructor. The connection is not connected to any database instance.
|
|
Create a connection to a database instance describe by tnsname . For authertification user and password are being used. As optional parameter, an Oracle-Environment env may be set for this connection.
|
|
Destructor. If a connection has been estabilshed previously, this connection is being erased. |
|
Create new BFile bfile , placed in directory dir with name fname. The directory should be created first on server, and file should exist at his place. |
|
Create a temporary large object (see class TLob) of type lobtype with caching mode cachemode. The temporary LOB structure lob is initialized during this call
|
|
Drop the connection to the database, if a connection had been estabilshed previously. |
|
Execute a query (an SQL-statement) query on the database server. All relevant information are store within the reference cur to a cursor object. prefetch stores, how many rows are to be fetched when executing Cursor::fetch() for the created cursor.
|
|
Execute a query (an SQL-Statement) query on the previously initialized database connection. A cursor is returned as a result. The user is responsible for destroying this cursor if it is not required any more.
|
|
Execute an update statement request on the database server. This method can be used to execute UPDATE, INSERT and DELETE SQL statements, which are not returning a cursor. |
|
Initialize the queue-instance queue to represent the advanced database queue named queue_name. |
|
Initialized a connection to the database specified by tnsnames for user user identified by password password . An optional Oracle environment env may be passed to the oracle server. |
|
Prepare and SQL-Statement sql. The cursor cur is accordingly initialized. For fetch-operations, an amount or rows to be prefetched prefetch may be specified. |
|
Returns the identification string of the Oracle server associated to this connection. |
|
Commit (accept) a previously started transaction. The transaction ends with either being committed or rolled back.
|
|
Roll back a previously started transaction. The transaction ends with either being committed or rolled back.
|
|
Start a new transaction |