Connecting Tech Pros Worldwide Forums | Help | Site Map

Oracle, Dataset Designer, and Transactions

maltobelli
Guest
 
Posts: n/a
#1: Sep 5 '06
I am building a windows forms app using VS2005 and the dataset designer to
connect to an Oracle backend. So far this has worked quickly and easily for
me to finish the app within the given timeframe.

I would love to add transactioning to some of the calls to add robustness.
I can begin the transaction on the tableadapter, but I cannot find a way to
enlist the various predefined commands for each tableadapter into the
transaction. Or do the commands automatically enlist themselves in the
transaction with a System.Data.OracleClient type connection?

Thanks in advance for any information.

Michael Nemtsev
Guest
 
Posts: n/a
#2: Sep 5 '06

re: Oracle, Dataset Designer, and Transactions


Hello maltobelli,

for oracle, transactions are implicit for each connection

mI am building a windows forms app using VS2005 and the dataset
mdesigner to connect to an Oracle backend. So far this has worked
mquickly and easily for me to finish the app within the given
mtimeframe.
m>
mI would love to add transactioning to some of the calls to add
mrobustness. I can begin the transaction on the tableadapter, but I
mcannot find a way to enlist the various predefined commands for each
mtableadapter into the transaction. Or do the commands automatically
menlist themselves in the transaction with a System.Data.OracleClient
mtype connection?
m>
mThanks in advance for any information.
m>
---
WBR,
Michael Nemtsev :: blog: http://spaces.msn.com/laflour

"At times one remains faithful to a cause only because its opponents do not
cease to be insipid." (c) Friedrich Nietzsche


Glenn
Guest
 
Posts: n/a
#3: Sep 8 '06

re: Oracle, Dataset Designer, and Transactions


If you're using .NET 2.0 you have the option of using TransactionScope.
Although this can have a performance hit.

The other option is to use transaction directly by extending your table
adapter with a BeginTransaction method. The method should first check that
the current connection is open. Then create a transaction from the adapters
Connection property and assign it to each command (I,U,D) and the
_commandCollection. Remember to check for nulls! Then return the
transaction. It's not a lot of work, honest.

I'd also recommend you take a look at ODP.NET. It's brimming with neat
stuff and the documenation is superb, all 1212 pages of it!

http://www.oracle.com/technology/tec...net/index.html

HTH

Glenn


"maltobelli" <maltobelli@discussions.microsoft.comwrote in message
news:A6B17F91-7832-4333-AC3F-AF87F6299FC4@microsoft.com...
Quote:
>I am building a windows forms app using VS2005 and the dataset designer to
connect to an Oracle backend. So far this has worked quickly and easily
for
me to finish the app within the given timeframe.
>
I would love to add transactioning to some of the calls to add robustness.
I can begin the transaction on the tableadapter, but I cannot find a way
to
enlist the various predefined commands for each tableadapter into the
transaction. Or do the commands automatically enlist themselves in the
transaction with a System.Data.OracleClient type connection?
>
Thanks in advance for any information.

Closed Thread