Home All Groups Group Topic Archive Search About

Oracle Rollback causing error with .NET 1.1

Author
8 Mar 2006 1:28 PM
Khurram
Hi,

I am calling a DBMS_Transaction.ReadWrite(); and later Rollback; from an
Oracle Stored Procedure. When I call this stored procedure with from an
ASP.NET page, using OracleClient.dll version 1.0.3.000 i get NO ERROR, but
when i use OracleClient.dll version 1.0.5.000 i get this ERROR;
"ORA-02074: cannot ROLLBACK in a distributed transaction".

Following is my configuration:
Windows XP, IIS 5.1
VS 2003, .NET framework 1.1
Oracle 9i Release 2

I have googled, tried searching MSDN but no one has given specific
resolution of the said issue although they say it is an issue :P.
Any insight will be most welcome ...

Author
8 Mar 2006 7:42 PM
Sahil Malik [MVP C#]
There are just so many reasons why this could be happening - are you using
MSDTC? ENterprise Services?

SM


Show quote
"Khurram" <Khur***@discussions.microsoft.com> wrote in message
news:47856EDD-5328-48B3-A83A-7299F021330F@microsoft.com...
> Hi,
>
> I am calling a DBMS_Transaction.ReadWrite(); and later Rollback; from an
> Oracle Stored Procedure. When I call this stored procedure with from an
> ASP.NET page, using OracleClient.dll version 1.0.3.000 i get NO ERROR, but
> when i use OracleClient.dll version 1.0.5.000 i get this ERROR;
> "ORA-02074: cannot ROLLBACK in a distributed transaction".
>
> Following is my configuration:
> Windows XP, IIS 5.1
> VS 2003, .NET framework 1.1
> Oracle 9i Release 2
>
> I have googled, tried searching MSDN but no one has given specific
> resolution of the said issue although they say it is an issue :P.
> Any insight will be most welcome ...
>
Author
9 Mar 2006 4:48 AM
Khurram
Its a standard 3-tier architechture, Browser(IE) - Web server(IIS) -
Database(Oracle). Why does it throw the error i mentioned with
OracleClient.dll version 1.0.5.000 and not with 1.0.3.000 ?
Iam using DBMS_Transaction because of nested procedure calls which use DML
statements, but i guess this is not the issue.

Show quote
"Sahil Malik [MVP C#]" wrote:

> There are just so many reasons why this could be happening - are you using
> MSDTC? ENterprise Services?
>
> SM
>
>
> "Khurram" <Khur***@discussions.microsoft.com> wrote in message
> news:47856EDD-5328-48B3-A83A-7299F021330F@microsoft.com...
> > Hi,
> >
> > I am calling a DBMS_Transaction.ReadWrite(); and later Rollback; from an
> > Oracle Stored Procedure. When I call this stored procedure with from an
> > ASP.NET page, using OracleClient.dll version 1.0.3.000 i get NO ERROR, but
> > when i use OracleClient.dll version 1.0.5.000 i get this ERROR;
> > "ORA-02074: cannot ROLLBACK in a distributed transaction".
> >
> > Following is my configuration:
> > Windows XP, IIS 5.1
> > VS 2003, .NET framework 1.1
> > Oracle 9i Release 2
> >
> > I have googled, tried searching MSDN but no one has given specific
> > resolution of the said issue although they say it is an issue :P.
> > Any insight will be most welcome ...
> >
>
>
>
Author
9 Mar 2006 6:46 AM
Khurram
Something similar to what I am trying to ask: http://www.error-bank.com/microsoft.public.dotnet.framework.adonet/1B18755A-9D88-4E38-ABA6-593B69F259F6@microsoft.com_Thread.aspx

Show quote
"Sahil Malik [MVP C#]" wrote:

> There are just so many reasons why this could be happening - are you using
> MSDTC? ENterprise Services?
>
> SM
>
>
> "Khurram" <Khur***@discussions.microsoft.com> wrote in message
> news:47856EDD-5328-48B3-A83A-7299F021330F@microsoft.com...
> > Hi,
> >
> > I am calling a DBMS_Transaction.ReadWrite(); and later Rollback; from an
> > Oracle Stored Procedure. When I call this stored procedure with from an
> > ASP.NET page, using OracleClient.dll version 1.0.3.000 i get NO ERROR, but
> > when i use OracleClient.dll version 1.0.5.000 i get this ERROR;
> > "ORA-02074: cannot ROLLBACK in a distributed transaction".
> >
> > Following is my configuration:
> > Windows XP, IIS 5.1
> > VS 2003, .NET framework 1.1
> > Oracle 9i Release 2
> >
> > I have googled, tried searching MSDN but no one has given specific
> > resolution of the said issue although they say it is an issue :P.
> > Any insight will be most welcome ...
> >
>
>
>
Author
9 Mar 2006 3:56 PM
Thomas H
Which database version are you connecting to?  Try adding this to your
connection string, I used to hit a similar error when working with 8i
clients using OLE DB- this will disable distributed transactions.
"DistribTX=0"  Unless you /are/ using distributed transactions...

Have you "skipped" .NET and executed the procedure directly from inside
SQL*Plus?  Try that first; that will eliminate OracleClient.dll completely;
maybe it's something inside the PL/SQL code that 1.0.3 couldn't catch.  I've
seen that before in software, where an old version has a bug that doesn't
trap errors- so newer "fixed" versions cause an error in a different spot.

-Thomas H

Show quote
"Khurram" <Khur***@discussions.microsoft.com> wrote in message
news:47856EDD-5328-48B3-A83A-7299F021330F@microsoft.com...
> Hi,
>
> I am calling a DBMS_Transaction.ReadWrite(); and later Rollback; from an
> Oracle Stored Procedure. When I call this stored procedure with from an
> ASP.NET page, using OracleClient.dll version 1.0.3.000 i get NO ERROR, but
> when i use OracleClient.dll version 1.0.5.000 i get this ERROR;
> "ORA-02074: cannot ROLLBACK in a distributed transaction".
>
> Following is my configuration:
> Windows XP, IIS 5.1
> VS 2003, .NET framework 1.1
> Oracle 9i Release 2
>
> I have googled, tried searching MSDN but no one has given specific
> resolution of the said issue although they say it is an issue :P.
> Any insight will be most welcome ...
>
Author
16 Mar 2006 3:50 PM
Khurram
As I mentioned I am using: Oracle9i Enterprise Edition Release 9.2.0.5.0
Setting DistribTX=0 in the connection string does not work.
Says: Keyword not supported: 'distribtx'
I used enlist=true and false, respectivly in the connection string to toggle
support for distributed transactions but to no avail. It threw the same error:
"ORA-02074: cannot ROLLBACK in a distributed transaction".
Also, FYI I did test my stored procedure first and then called it from the
application.
Khurram
Show quote
"Thomas H" wrote:

> Which database version are you connecting to?  Try adding this to your
> connection string, I used to hit a similar error when working with 8i
> clients using OLE DB- this will disable distributed transactions.
> "DistribTX=0"  Unless you /are/ using distributed transactions...
>
> Have you "skipped" .NET and executed the procedure directly from inside
> SQL*Plus?  Try that first; that will eliminate OracleClient.dll completely;
> maybe it's something inside the PL/SQL code that 1.0.3 couldn't catch.  I've
> seen that before in software, where an old version has a bug that doesn't
> trap errors- so newer "fixed" versions cause an error in a different spot.
>
> -Thomas H
>
> "Khurram" <Khur***@discussions.microsoft.com> wrote in message
> news:47856EDD-5328-48B3-A83A-7299F021330F@microsoft.com...
> > Hi,
> >
> > I am calling a DBMS_Transaction.ReadWrite(); and later Rollback; from an
> > Oracle Stored Procedure. When I call this stored procedure with from an
> > ASP.NET page, using OracleClient.dll version 1.0.3.000 i get NO ERROR, but
> > when i use OracleClient.dll version 1.0.5.000 i get this ERROR;
> > "ORA-02074: cannot ROLLBACK in a distributed transaction".
> >
> > Following is my configuration:
> > Windows XP, IIS 5.1
> > VS 2003, .NET framework 1.1
> > Oracle 9i Release 2
> >
> > I have googled, tried searching MSDN but no one has given specific
> > resolution of the said issue although they say it is an issue :P.
> > Any insight will be most welcome ...
> >
>
>
>

AddThis Social Bookmark Button