Skip to Main Content

Security Software

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

ORA-02089: COMMIT is not allowed in a subordinate session

838271Mar 14 2011
Hi Experts,
Calling oracle Stored Procedure call in side Adapter code. And stored procedure will create an user in Database Table (i.e multiple tables).

If any error encounters, Stored Procedure will roll back changes, if everything goes fine, Stored Procedure will commit changes.

Case 1:
I have called stored proc using JDBC connection:
conn = DriverManager.getConnection(url, "UserName", "Password");

Then called Stored procedure, its working fine.

Case 2:

Got connection from Weblogic server DataSource, then executed same commands (i.e Just creating connection only changed), Then got following error:

-----------------------------------------------------------------------------------------------------
ORA-02089: COMMIT is not allowed in a subordinate session
ORA-06512: at "PROCEDURE_NAME", line 1234
ORA-06512: at line 1
-----------------------------------------------------------------------------------------------------

The ERROR raised line of Stored procedure contains 'Commit', statement.


Could you help me, how I can solve this issue.

thanks
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Apr 11 2011
Added on Mar 14 2011
0 comments
327 views