Is ths Transaction Handling Write or Wrong ?

I little bit hesitate about Transaction handling in my application. I want to add data to database, before do this following steps should happen
# add data to account table
# update account serial which locate another table
# add data to monthtrm table
# update monthtrm serial which locate another table
In order to success this step I used container manager transaction below show that code
@TransactionAttribute(TransactionAttributeType.REQUIRED)
    public void addNewFixDepositAccount(Account account, String cusId, String branchCode, int newSerial, String userCode) {
        try {
          //add data to account table
          this.create(account);
                //update the SystemParameter table with new saving serial
                systemParameterFacade.setFdSerial(newSerial);
          //add data to monthtrn tabel     
          monthTrnFacade.create(monthTrn);
                //update the SystemParameter table with new monthtrn serial
                systemParameterFacade.setTrnSerial(nxtTranSerial);
     } catch (CopException e) {
     if (e.getStackTrace().length > 0) {
                System.out.println("Custom Massage :-" + e.getMessage());
                System.out.println("Called Class :-" + e.getCalledClass());
                System.out.println("Exception Handling Class :- " + getClass());
                System.out.println("Calling Method :-" + Thread.currentThread().getStackTrace()[1].getMethodName());
                System.out.println("Called Method :-" + e.getCalledMethod());
                System.out.println("Exception Line Number :-" + e.getStackTrace()[21].getLineNumber());
                System.out.println("Date and Time :- " + e.getDateTime());
                System.out.println("Exception Type :-" + e.getCause().toString());
            } else {
                System.out.println("Custom Massage :-" + e.getMessage());
                System.out.println("Called Class :-" + e.getCalledClass());
                System.out.println("Exception Handling Class :- " + getClass());
                System.out.println("Calling Method :-" + Thread.currentThread().getStackTrace()[1].getMethodName());
                System.out.println("Called Method :-" + e.getCalledMethod());
                System.out.println("Date and Time :- " + e.getDateTime());
                System.out.println("Exception Type :-" + e.getCause().toString());
}   Add data to account
    public void create(Account account) throws CopException {
        try {
            em.persist(account);
            em.flush();
            em.clear();
        } catch (Exception e) {
            context.setRollbackOnly();
            throw new CopException("Can't Add Account", e, getClass().toString(), Thread.currentThread().getStackTrace()[1].getMethodName());
  Add data to monthtrn
    public void create(MonthTrn monthTrn) throws CopException {
        try {
            em.persist(monthTrn);
            em.flush();
            em.clear();
        } catch (Exception e) {
            context.setRollbackOnly();
            throw new CopException("Can't Add MonthTrm", e ,getClass().toString(),Thread.currentThread().getStackTrace()[1].getMethodName());
Update Account serial
    public void setFdSerial(int fdSerial) throws CopException {
        try {
            Query query = em.createQuery("UPDATE SystemParameter s SET s.fdSerial = :fdSerial");
            query.setParameter("fdSerial", fdSerial);
            query.executeUpdate();
            em.flush();
        } catch (Exception e) {
            context.setRollbackOnly();
            throw new CopException("Can't Update FD Serial", e, getClass().toString(), Thread.currentThread().getStackTrace()[1].getMethodName());
   Update Trnserial
    public void setTrnSerial(int trnSerial) throws CopException {
        try {
            System.out.println("Trn Serial : " + trnSerial);
            Query query = em.createQuery("UPDATE SystemParameter s SET s.trnSerial = :trnSerial");
            query.setParameter("trnSerial", trnSerial);
            int result = query.executeUpdate();
            System.out.println("Number of updated records in transaction Serial :- " + result);
        } catch (Exception e) {
            context.setRollbackOnly();
            throw new CopException("Can't Update Trn Serial", e, getClass().toString(), Thread.currentThread().getStackTrace()[1].getMethodName());
    }Exception Class
package bank.exception;
import java.text.DateFormat;
import java.text.SimpleDateFormat;
import javax.ejb.ApplicationException;
* @author dinesh
@ApplicationException(rollback = true)
public class CopException extends Exception {
    private String calledClass;
    private String calledMethod;
    public String getDateTime() {
        DateFormat dateFormat = new SimpleDateFormat(" yyyy-MM-dd HH:mm:ss");
        java.util.Date date = new java.util.Date();
        return dateFormat.format(date);
    public CopException(String string, Exception ae, String className, String methodName) {
        super(string, ae);
        this.getDateTime();
        this.setCalledClass(className);
        this.setCalledMethod(methodName);
    public String getCalledClass() {
        return calledClass;
    public void setCalledClass(String calledClass) {
        this.calledClass = calledClass;
    public String getCalledMethod() {
        return calledMethod;
    public void setCalledMethod(String calledMethod) {
        this.calledMethod = calledMethod;
Is this way correctly handle Transaction? If I wrong please give me you're precious advice to improve my program efficiency, please give some comments

Sounds fine to me. If you have duplicated yourself too much, you can refactor the model later to remove duplication. If there is no duplication, then separate models was the right choice.

Similar Messages

  • Transaction Handling in Forte

    I have a serious problem with Forte Transaction handling.
    If a transaction gets aborted through the statement Transaction.Abort
    (not because of a database exception), looks like some resources/locks
    are not released as a result of which if the current screen is closed,
    Forte does not allow the screen to be re-opened. It gives some vague
    error like 'Incorrect syntax near '.'
    Following is the piece of code. I would appreciate it if someone could
    give me a solution.
    Thanks,
    Begin Transaction
    commitFlag = true;
    Function1(commitFlag);
    if commitflag
    Function2(commitFlag);
    end if;
    if NOT commitflag
    ex :UserDefinedException = new;
    Transaction.Abort(ex,true);
    end if;
    Exception
    When ex : UserDefinedException do
    End Transaction;
    Function1(commitFlag In/Out)
    SQL Select some_flg from some_tab;
    If some_flag = 'A'
    ex : UserDefinedException = new;
    commitFlag = false;
    raise ex;
    end if;
    update some_tab with some_flg;
    Exception
    when ex:UserDefinedException do
    Function2(commitFlag In/Out)
    SQL Select some_flg from another_tab;
    If some_flag = 'A'
    ex : UserDefinedException = new;
    commitFlag = false;
    raise ex;
    end if;
    update another_tab with some_flg;
    Exception
    when ex : UserDefinedException do
    }

    Transaction processing in FORTE is not straight forward. The wrong order
    of statements may break your code. In your example I can suggest to
    remove exceptions processing blocks from methods Function1 and
    Function2. If transaction aborts in Function1, Function2 won't be
    executed, so you don't need to use your commitFlag. You should process
    an exception what is generated by transaction.abort in the same method
    where transaction started or higher, otherwise it does work properly.
    Hope it helps.
    Igor Teselko.
    RAO Meena wrote:
    >
    I have a serious problem with Forte Transaction handling.
    If a transaction gets aborted through the statement Transaction.Abort
    (not because of a database exception), looks like some resources/locks
    are not released as a result of which if the current screen is closed,
    Forte does not allow the screen to be re-opened. It gives some vague
    error like 'Incorrect syntax near '.'
    Following is the piece of code. I would appreciate it if someone could
    give me a solution.
    Thanks,
    Begin Transaction
    commitFlag = true;
    Function1(commitFlag);
    if commitflag
    Function2(commitFlag);
    end if;
    if NOT commitflag
    ex :UserDefinedException = new;
    Transaction.Abort(ex,true);
    end if;
    Exception
    When ex : UserDefinedException do
    End Transaction;
    Function1(commitFlag In/Out)
    SQL Select some_flg from some_tab;
    If some_flag = 'A'
    ex : UserDefinedException = new;
    commitFlag = false;
    raise ex;
    end if;
    update some_tab with some_flg;
    Exception
    when ex:UserDefinedException do
    Function2(commitFlag In/Out)
    SQL Select some_flg from another_tab;
    If some_flag = 'A'
    ex : UserDefinedException = new;
    commitFlag = false;
    raise ex;
    end if;
    update another_tab with some_flg;
    Exception
    when ex : UserDefinedException do

  • Transaction Handling - JDBC Receiver Adapter - Multiple SP Calls

    Hello,
    I have the following scenario:
    I send an XML-SQL structure with multiple statment elements (each of them calling a different stored procedure). A stored procedure raises an error back to the JDBC Receiver Adapter in case of error.
    Is it possible to have transaction handling in the JDBC Receiver to ensure:
    - Commit only after ALL stored procedures where succesful (no error risen during calls)
    - Rollback of ALL already called stored procedures in case an error has been risen
    How can I implement these requirements in the JDBC Receiver Adapter?

    One more comment, I have found the following info for JDBC Drivers:
    <i> "JDBC driver's default is to autocommit, meaning that the result of every SQL statement is permanent as soon as it is executed. This is why the course hasn't had to be concerned with transactions so far, and is perfectly acceptable in many cases."</i>
    So I think that each SP-Call is automatically commited in case autocommit on JDBC Driver Level is set to "true". Does anyone know where I can change these settings? Directly on JDBC Receiver Adapter or do I have to go to Visual Admin for those changes?

  • Removing the entity object commit from transaction handler

    Hi,
    The business reuirement of the OAFWK page developed by us is as explained below:
    The basic functionality is of updating the attributes of items attached to the change order.
    The UI components displayed in the page(Item attribute changes region) are built based on the properties of the item attributes as LOV,poplist,textbox etc..
    The dynamic VO mapped to these UI components is based on a standard entity object.
    User operation:Select any attribute group and click on Go button.The Item attributes of the attribute group are displayed.Enter values in the Item Attributes and click on Apply button of the region.(changes made in the attributes related to the attribute group are committed to the database using
    &lt;Root AM&gt;.getTransaction.commit()).
    Now we have two such regions in the same page.
    On top of the page the item attributes of _{color:#800000}&lt;Item Type X&gt;{color}_ are displayed.
    Down the page, the item attributes of {color:#0000ff}&lt;_Item Type Y_&gt;{color} are displayed.
    In few special cases i.e for few item attributes, on click of Apply button for {color:#0000ff}_Item Y_{color} , the attributes of {color:#800000}I_tem X_{color} are to be updated by calling a PLSQL API.When Apply button in the Item attributes of _{color:#0000ff}Item Type Y{color}_ is clicked,the execution of controllers is :
    1.Controllers of Item attribute changes region of {color:#800000}&lt;Item Type X&gt; {color}The dynamic VO is built for the item attributes of Item Type X
    2.Controllers of the Item attribute changes region of {color:#0000ff}Item Type Y{color} The dynamic VO is built for the item attributes of Item Type Y.In the last controller of the hierarchy, the PLSQL API call is included(by invoking the method in AM) to update few attribute values of {color:#800000}Item Type X and finally &lt;Root AM&gt;.getTransaction().commit().
    Problem : The updated values by PLSQL API for {color:#800000}_Item Type X_{color} are not reflected in the database but indeed the values entered by user for {color:#800000}_Item Type X_{color} in the top of the page are committed(The Apply button for {color:#800000}_Item Type X_{color} is not clicked).
    _&gt;&gt;Please note that the dynamic VOs of both the Item Types are built on the same standard Entity Object_
    I am struggling to know the reason why the values updated by PLSQL API are overwrittem by the values in the entity object even though the PLSQL API is called in the last controller of execution.Please let me know if there is any OAFWK constraint.
    I tried the approach of removing the commit of the dynamic VO built in the region of {color:#800000}_Item Type X&gt;_ {color}{color:#000000}I fetched the entity implementation of the dynamic VO row and used removeandRetain(),revert().But this approach failed.I am referring to the jdevdoc for the built-in methods.
    {color}
    Now the requirement is the latest values updated by API (for {color:#800000}_Item Type X_{color}) should be committed in the database but not the values updated by the entity object for {color:#800000}_Item Type X_ {color}{color:#000000}in the item attributes region{color}.
    There should a single commit for the entire transaction of the page.
    Is there any chance to remove the commit of item attributes of {color:#800000}_Item X_{color} alone from the transaction handler?There are few methods in oracle.jbo.server.EntityImpl class such as doRemoveFromTransactionManager().But these methods are either protected or private.So classes of other packages cannot access them.
    So pelase suggest me if there is a workaround for this scenario.
    Thanks and Regards,
    Kiran
    Edited by: Kiran.A on Sep 20, 2008 3:34 AM

    Hi Sumit,
    Yes I agree on that front that updating the same record through PLSQL and EO is not the right approach.
    But the business requirement is as such and we do not have any workaround for this.
    Please let me know if there is any way to avoid the EO commit by removing from transaction listener.
    Regards,
    Kiran

  • Transaction Handling in webservice based partnerlink

    What is the transaction handling mechanism for parnerlink which calls webservice (not native BPEL/ESB)?
    REgards
    priyadarshi

    It is SDO using I think
    It should be not SOAP action, because it is not support transactions

  • Transaction handling in Siebel

    Hi
    Can I implement transaction handling in Siebel? If yes, how can I implement it?
    Thanks
    Gana

    This pdf give some background on transactions and error handling within esb 10g.
    http://www.oracle.com/technology/products/integration/esb/files/esb-transactions-errorhandling.pdf
    not very detailed

  • Transaction Handling across Procedures

    In the ODI Best Practice Guide for Data Warehouses I came across the following (page 100):
    "ODI procedures include an advanced mechanism for transaction handling across multiple steps or even multiple procedures."
    It states that transaction handling can occur across multiple procedures. I could not get this to work.
    I created a procedure with just one step that inserts into a table. In the step I have set the Transaction dropdown to Transaction 0 and the Commit dropdown to No Commit. However, when I execute the procedure the insert is committed as we terminate the session.
    Any ideas how this commit can be prevented?

    ok, I figured out that parameters to the JDBC driver can be specified at the properties tab of the data server.
    So I presume this will be autocommit = false or sth. similar
    I still have to try this out.

  • Osb 11g transaction handling

    Hi,
    I have a problem with transaction handling in OSB 11g. When I add a report action, error messages disappear.
    The process is the following:
    jms-queue -> proxy-service ->business-service ->EBS webservice.
    In the proxy-service I add an error-handler at node-level. In this error-handler I log the error-message in the server log. In the regular process there is a request and response-pipeline.
    When I add a message on the queue and when the response from EBS is negative, the message is placed on a errorqueue. That's ok.
    When I add a report-action to the error-handler and then I put another message on the queue, the message is disappeared. It is not on the error-queue and not on the normal queue. When I look in the database there is an extra row added.
    I use the default datasource(wlsbjmsrpDataSource).
    I found for example this blog: http://biemond.blogspot.nl/2010/11/global-transactions-and-quality-of.html ; but I can't find an example with writing to a database and a rollback to an errorqueue. The report-action needs it's own transaction.
    In the weblogic console -> datasources -> transaction I unchecked "Keep Connection After Local Transaction" but that didn't work.
    What kind of options is possible?
    Herman

    I cant believe i was answered by the famous Anuj!.
    You were correct. The weird thing, is that in publish actions the QoS is not propagated onto the target of that Publish per se.
    We say this, becouse the Local PS has the Transaction Required = True, ergo the QoS is Exactly Once all along its message flow. It also propagates in the service callout´s and Route Node´s. Thats why we, trying to avoid redundance, didnt specified it in the publish action.
    Thank you very much.
    Regards.
    Mario.

  • How to handle write errors in non blocking sockets

    Hi,
    I'm using sockets registered with a Selector for read operations. I've seen code examples that put the SocketChannel in non blocking mode before registering it with the selector, and in fact not doing so would cause an IllegalBlockingModeException to be thrown.
    My problem is that I can't handle write errors. The call to write() returns inmediately without throwing any exception. Even worse, when the network timeout expires the selector wakes up and I get an exception on read(). So I can't tell the difference between a real read error and a write error.
    What can I do? Is there a magic method I haven't heard about?
    Thanks

    ejp wrote:
    OK, so what happens is this: you write from your ByteBuffer; if there is room in the socket send buffer, the data is transferred and the transfer count is returned. (If there isn''t, the write returns zero and nothing has happened.) Your application code then continues. Meanwhile TCP is trying to send the data in the send buffer and get an ACK from the peer. If the peer is down as per your test, eventually those write attempts will time out. You will then get a connection reset exception on the next read or write.
    Even worse, when the network timeout expires the selector wakes upCorrect, to tell you there is an error condition pending. This is good, not bad.You're right. This way my program can know that something happened.
    But I still don't understand what the difference between a failed write() and a failed read() is. I mean, the error condition may appear during a send attempt, or it may appear after sending. In both cases I get an error when trying to read. How can my program know if data have been received by the other end?
    Do I have to implement ACK messages in the application level protocol??? It'd be nice if TCP could do this for me...

  • Transaction handling in EJBs

    i dont know ejb�s handle transaction.
    any sugesstions??????
    sorry my english, ciao

    http://www.google.com/search?hl=en&q=EJB+transaction+handling
    Especially look at this one:
    http://www.kevinboone.com/ejb-transactions.html

  • Web Service transaction handling

    Hello,
    Is it possible in SAP NW to execute several calls to Web Services in one LUW (logical unit of work)? And be able to commit or rollback?
    Where can i find information about Web Service transaction handling in SAP?
    Best regards
    Ute

    I haven't found any official info on it, but my simple testing (mainly via ST05) indicates that you should be able to call multiple web services within a single LUW -  there seems to be no implicit "commit work" issued by the framework (unlike remote RFC calls).
    Jonathan

  • Exception generated during defered local transaction handling

    Hi All,
    We are using data direct connect 3.3 driver with MS SQL Server 7 on WebSphere 4.0. We are getting the exception "Exception generated during defered local transaction handling". Anyone encountered similar problem?> please let me know the solution. I am pasting the stack trace here.
    Thanks in advance.
    Regards,
    Girish
    [7/29/05 9:19:31:210 EDT] 37c1f1 SystemOut U 2005-07-29 09:19:31,177 [Servlet.Engine.Transports:10] ERROR com.xyz.nuuw.bus.dao.JDBCWrapper -livdsqa11122643171177
    java.sql.SQLException: [IBM][SQLServer JDBC Driver]Exception generated during defered local transaction handling. See next exception via SQLException.getNextException for details.
    at com.ibm.websphere.jdbc.base.BaseExceptions.createException(Unknown Source)
    at com.ibm.websphere.jdbc.base.BaseExceptions.getException(Unknown Source)
    at com.ibm.websphere.jdbc.base.BaseExceptions.getException(Unknown Source)
    at com.ibm.websphere.jdbc.base.BaseConnection.transactionableWorkStarting(Unknown Source)
    at com.ibm.websphere.jdbc.base.BaseStatement.commonExecute(Unknown Source)
    at com.ibm.websphere.jdbc.base.BaseStatement.executeQueryInternal(Unknown Source)
    at com.ibm.websphere.jdbc.base.BasePreparedStatement.executeQuery(Unknown Source)
    at com.ibm.websphere.jdbcx.base.BasePreparedStatementWrapper.executeQuery(Unknown Source)
    at com.ibm.ejs.cm.cache.CachedStatement.executeQuery(CachedStatement.java:312)
    at com.ibm.ejs.cm.proxy.StatementProxy.executeQueryCommon(StatementProxy.java:410)
    at com.ibm.ejs.cm.proxy.PreparedStatementProxy.executeQuery(PreparedStatementProxy.java:53)
    at com.xyz.nuuw.bus.dao.JDBCWrapper.getdata(JDBCWrapper.java:164)
    at com.xyz.nuuw.bus.dao.AccountSetupPH.getKeyID(AccountSetupPH.java:445)
    at com.xyz.nuuw.bus.bo.AccountSetupBO.getKeyID(AccountSetupBO.java:50)
    at com.xyz.nuuw.accountSetup.bus.ejb.AccountSetupSBBean.getKeyID(AccountSetupSBBean.java:85)
    at com.xyz.nuuw.accountSetup.bus.ejb.EJSRemoteStatelessAccountSetupSB_14ea1086.getKeyID(EJSRemoteStatelessAccountSetupSB_14ea1086.java:99)
    at com.xyz.nuuw.accountSetup.bus.ejb._AccountSetupSB_Stub.getKeyID(_AccountSetupSB_Stub.java:310)
    at com.xyz.nuuw.bus.AccountSetupBD.getKeyID(AccountSetupBD.java:73)

    I am currently working with IBM on a similar problem with WAS 5.1 and SQL Server 2000. The SQLException has a nested exception that can be retrieved using the getNextException() method. This will give you some more information as to what is causing the problem. Ours seems to be triggered by a dropped connection at the SQL end. normally WAS will recover from that gracefully, but in our situation it is not.
    Doug

  • Transaction handling in XI

    hi guys;
    What I am trying to look is  XI tries to insert data in database and some error happens while inserting data so how xi rolls back the trasaction and how can we write a logic to send a email about this error to any  person.

    Mudit,
    <i>how can we write a logic to send a email about this error to any person.</i>
    You can create Alerts, which will trap all errors occuring in your process and send an email to the necessary person.
    To create alerts , this blog can help you out,
    /people/michal.krawczyk2/blog/2005/09/09/xi-alerts--step-by-step
    From SP14 onwards, activation of end to end monitoring is not needed for Alerting. Refer to this note 870232 for this info.
    If you are blow SP14, then also check this blog,
    /people/michal.krawczyk2/blog/2005/09/09/xi-alerts--troubleshooting-guide
    To send an EMAIL, assign an EMAIL ID to the corresponding user in the transaction SU01 and then set up SCOT and you can send emails when the ALERT is triggered.
    <i>some error happens while inserting data so how xi rolls back the trasaction</i> Internally , you can set the TRANSCATON handling of XI. Mostly, this transcation handling for errors dyuring insertion is handled by the Database itself.
    Regards,
    Bhavesh

  • Non-transactional cursor writes block reads

    I'm opening a cursor without using a transaction like so:
    CursorConfig conf = new CursorConfig();
    Cursor cursor = db.openCursor(null, conf);
    I then iterate over the items, sometimes replacing a value. I want to be able to read (and maybe write) to any value from another thread while the cursor is still open, but gets result in the following error:
    com.sleepycat.je.DeadlockException: (JE 3.3.74) Lock expired. Locker 32098350 -1_NioProcessor-3_ThreadLocker: waited for lock on database=settings LockAddr:1537969 node=2623139 type=READ grant=WAIT_NEW timeoutMillis=500 startTime=1229438453225 endTime=1229438453730
    Owners: [<LockInfo locker="11743647 -1_NioProcessor-1_ThreadLocker" type="WRITE"/>]
    Waiters: []
    I would have expected that outside a transaction any update made through a cursor would be applied immediately, but instead the record is locked until the cursor is closed. This happens whether or not je.env.isTransactional is set to true.
    Setting je.env.isLocking to false gives me the cursor behaviour that I want, but I'm not sure what else is affected by this setting, and the javadoc comment is just vaguely worrying rather than helpful ("This property should be set to false only in special circumstances when it is safe to run without record locking.")
    I am not planning on using any transactions in this application.

    Cormac,
    I was looking through the documentation for a reference page to direct you to, and I realized that probably the clearest explanation in the javadoc is in the com.sleepycat.je.LockMode page here: [http://www.oracle.com/technology/documentation/berkeley-db/je/java/com/sleepycat/je/LockMode.html]. There is a reference to it from the CursorConfig page, but I can see that the link between the two pages is not that clear.
    From the LockMode javadoc, there is this paragraph.
    bq. Locking Rules \\ Together with CursorConfig, TransactionConfig and EnvironmentConfig settings, lock mode parameters determine how records are \\ locked during read operations. Record locking is used to enforce the \\ isolation modes that are configured. Record locking is summarized below for \\ read and write operations. For more information on isolation levels and \\ transactions, see [Writing Transactional Applications|http://www.oracle.com/technology/documentation/berkeley-db/je/TransactionGettingStarted/index.html]. \\ With one exception, a record lock is always acquired when a record is \\ read or written, and a cursor will always hold the lock as long as it is \\ positioned on the record. The exception is when [READ_UNCOMMITTED|http://www.oracle.com/technology/documentation/berkeley-db/je/java/com/sleepycat/je/LockMode.html#READ_UNCOMMITTED] \\ is specified, which allows a record to be read without any locking.
    Transactional cursors, by default, hold all locks until the cursor is closed. In your case, you are using a non transactional cursor, and locks are not collected the same way. But a lock for modified record is still taken in a non transactional cursor, and is held as long as the cursor is positioned at that record, to provide cursor stability. I am guessing that is what is happening in your case. If you close the cursor or move to a different position, you will be releasing the lock.
    In a second posting, you comment on your experiences using the je.env.locking property. That property is really only to be used in cases where the application is very constrained and has high performance requirements; frankly, that was put in for a particular set of power users and we really don't recommend it for general purpose use. (We should doc it better too). One characteristic is that it disables log cleaning, because the lack of locks makes it impossible for us to properly coordinate access to the data from the log cleaning threads.
    Regards,
    Linda
    Edited by: Linda Lee on Dec 16, 2008 2:19 PM (changed " link between the two pages is that clear" -> not that clear)

  • Database adapter transaction handling

    I am assuming that when one writes (insert/update/delete) to a database via the appropriate adapter that each write action does an auto-commit, or rollback. I want to have control of this commit/rollback transaction for both sync and async database adapter interactions. How do I turn off 'auto' transactions and I issue an appropriate commit/rollback.
    Thanks - Casey

    Hi Venajamin,
    If you have selected the option NO TRANSACTION HADLING, it implies that the Transaction Handliong of your Database has been truned off.
    <i>Set the indicator if you want to deactivate the logical unit of work, which the JDBC adapter requires to guarantee that data in the database is consistent.
    <b>This option is required for JDBC drivers that do not support transactions.</b> To avoid data inconsistencies in the database when the isolation level is lowered, ensure that multiple database transactions cannot access the database simultaneously.</i>
    From the link,
    http://help.sap.com/saphelp_nw04/helpdata/en/64/ce4e886334ec4ea7c2712e11cc567c/content.htm
    Regards,
    Bhavesh

Maybe you are looking for