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

No object inserted if entity only contain ID attribute and set to IDENTITY

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 1.0.0
    • 1.2.0
    • kernel
    • None

    Description

      If the entity only contains the ID column and the generated strategy set to IDENTITY, then when saving this object, then will not insert record to database.

      @Entity
      @Table(name="A")
      public class A {
      @Id
      @GeneratedValue(strategy=GenerationType.IDENTITY)
      public int id;
      }

      Attachments

        Activity

          People

            ppoddar@apache.org Pinaki Poddar
            supermaneddie Eddie Man
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: