on 05-29-2009 1:29 PM
Hi,
I read something about this topic some weeks before, but can somebody confirm this:
oracle-jdbc driver has by default autocommit on.
And I have no chance to turn it off without programming a custom action?
(I don't like custom actions but I want to set autocommit off)
Thanks
Matthias
There is no way to set the auto commit off in SQL Queries.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hello, Matthias.
You'll need custom action(s) in order to do database transactioning across multiple actions in a transaction. This is primarily due to the fact that:
1) You cannot turn off autocommit
2) You cannot be guaranteed that multiple SQLQuery actions will use the same database connection
The best approach is to design custom action(s) similar to the transactional JCO action(s) - one to initiate the connection/transaction, one to execute SQL calls, one to do a rollback, and one to do a commit. The actions also need to be "linked" in such a way that the connection is shared - the JCO actions provide such a pattern.
It would actually be fairly trivial to do the actual code, but the complexity of the "linked actions" can be a bit challenging. Maybe I'll write a set of these actions or "pseudocode" them so that someone else can write them - as long as whoever writes them agrees to "open source" them.
Rick
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hello Rick,
oh, I thought it is just an action block and set autocommit to false.
Your solution sounds a bit more complicated. I'm not very familiar with java so I think I'm not the right person for this job. But I'm interested in the solution if someone will create the custom actions.
Thanks for your help.
Matthias
Matthias,
The work is already done for v12.1...
[https://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/10bfa608-103b-2c10-6399-e41044c3363e|https://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/10bfa608-103b-2c10-6399-e41044c3363e]
Other custom solutions can be found here:
[https://wiki.sdn.sap.com/wiki/display/xMII/Customization|https://wiki.sdn.sap.com/wiki/display/xMII/Customization]
Regards,
Sam
It's probably not what you are looking for, but you can handle the commits in the SQL Query itself using Rollbacks and the like.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
8 | |
7 | |
3 | |
2 | |
2 | |
1 | |
1 | |
1 | |
1 | |
1 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.