OpenJPA
  1. OpenJPA
  2. OPENJPA-2170

Multiple INSERT of the same row in batch update manager

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Minor 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

        No work has yet been logged on this issue.

          People

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

            Dates

            • Created:
              Updated:
              Resolved:

              Development