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

Multiple INSERT of the same row in batch update manager

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 2.2.0, 2.3.0
    • Fix Version/s: 2.3.0
    • Component/s: jdbc
    • Labels:
      None

      Description

      When trying to persist multiple different entities to the data base using the batching update manager, if an INSERT failed, the update manager will erroronously attempt to INSERT the same row to the database again. E.g.

      em.persist(entity_type_1_id_1); // failed with a SQLException on INSERT
      em.persist(entity_type_2_id_2);
      em.flush();

      will cause 2 insert of :

      INSERT ENTITY_TYPE_1 ...... WHERE ID="ID_1"
      Failed with an SQLException and insert the same row again.
      INSERT ENTITY_TYPE_1 ...... WHERE ID="ID_1"

        Activity

        There are no comments yet on this issue.

          People

          • Assignee:
            allee8285 Albert Lee
            Reporter:
            allee8285 Albert Lee
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development