2 Replies Latest reply on Nov 22, 2007 2:15 PM by i o

    SELECT FOR UPDATE, PostgreSQL vs DB2

    i o Newbie

      Hi

      I have a method which REQUIRES_NEW transaction, which perform

      a SELECT ... FOR UPDATE on one row.

      On PostgreSQL everything is fine and the query locks correctly, while if i use DB2 as datasource, it seems
      that my select for update doesnt actually lock anything, and if i perform another invocation to this method, or some other selects for update from other consoles, they can succeed...

      What's wrong?

        • 1. Re: SELECT FOR UPDATE, PostgreSQL vs DB2
          i o Newbie

          actually, when i try to do a concurrent select for update calling again my same method, i get this:

          [JDBCExceptionReporter] [SQL7973] Il pacchetto di creazione SQL per JBPKGCAA in JBOSS non è riuscito. Causa. . . . . : La richiesta di creazione del pacchetto ha rilevato un errore. Il nome del pacchetto potrebbe essere JBPKGCAA in JBOSS.

          not very helpful tough

          • 2. Re: SELECT FOR UPDATE, PostgreSQL vs DB2
            i o Newbie

             

            "paoletto" wrote:
            actually, when i try to do a concurrent select for update calling again my same method, i get this:

            [JDBCExceptionReporter] [SQL7973] Il pacchetto di creazione SQL per JBPKGCAA in JBOSS non è riuscito. Causa. . . . . : La richiesta di creazione del pacchetto ha rilevato un errore. Il nome del pacchetto potrebbe essere JBPKGCAA in JBOSS.

            not very helpful tough


            it means "SQL creation packet for JBPKGCAA in JBOSS didnt succeed. Cause: creation request for the packet found an error. Packet name could be JBPKGCAA."