Uploaded image for project: 'OpenJPA'
  1. OpenJPA
  2. OPENJPA-182

db2 update lock syntax WITH <isolation> USE AND KEEP UPDATE LOCKS

    XMLWordPrintableJSON

Details

    • New Feature
    • Status: Closed
    • Major
    • Resolution: Fixed
    • None
    • 0.9.7
    • jdbc
    • None
    • db2 database driver for zOS, AS400, Unix, Windows, Linux

    Description

      A while back we changed the syntax of update locking from FOR UPDATE OF to WITH RS USE AND KEEP UPDATE LOCKS. Additional changes are required because
      1. if isolation=serializable is configured, then the syntax should be WITH RR USE AND KEEP UDPATE LOCKS
      2. when using DB2/400 on iSeries machines, the syntax is WITH RS USE AND KEEP EXCLUSIVE LOCKS or WITH RR USE AND KEEP EXCLUSIVE LOCKS because DB2/400 only supports read or exclusive locks.
      3. DB2 supports both a FETCH FIRST ROWS and update LOCKS clauses.

      So we change supportsLockingWithSelectRange = true in the AbstractDB2Dictionary class and change the DB2Dictionary to append the correct LOCKS syntax depending on vendor, release and isolation level.

      Attachments

        1. JIRA182-subselect.patch
          3 kB
          Ritika Maheshwari
        2. openJPA182.patch
          13 kB
          Ritika Maheshwari
        3. OPENJPA-182.patch
          4 kB
          Patrick Linskey
        4. OPENJPA-182.patch
          14 kB
          Patrick Linskey
        5. openjpa182TestCase.jar
          1 kB
          Ritika Maheshwari

        Issue Links

          Activity

            People

              Unassigned Unassigned
              wisneskid David Wisneski
              Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: