Uploaded image for project: 'JBoss Enterprise Application Platform'
  1. JBoss Enterprise Application Platform
  2. JBEAP-4475

[GSS] (7.0.z) HHH-5393: Repeated Column in mapping when using MapKeyColumn

    XMLWordPrintable

Details

    • Bug
    • Resolution: Done
    • Major
    • 7.0.3.CR1, 7.0.3.GA
    • 7.0.0.CR1
    • Hibernate
    • None
    • EAP 7.0.3

    Description

      @MapKey is not designed for using Embeddables in maps, so @MapKeyColumn should be used. However when using the following annotation you get a "Repeated Column in Mapping" error:

      @ElementCollection
      @CollectionTable(name = "TRANSACTIONS_EVENTS",
      joinColumns = @JoinColumn(name = "TRANSACTION_ID") )
      @MapKeyColumn(name = "type", insertable=false, updateable=false)
      @MapKeyEnumerated(EnumType.STRING)
      private Map<EventType, TransactionEvent> events = new HashMap<EventType, TransactionEvent>();

      Also see: https://hibernate.atlassian.net/browse/HHH-5393

      Attachments

        Issue Links

          Activity

            People

              gbadner@redhat.com Gail Badner (Inactive)
              rhn-support-dstephan David Stephan
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: