Skip to main content



      Home
Home » Eclipse Projects » EclipseLink » @AttributeOverride ignored with @Embedded
@AttributeOverride ignored with @Embedded [message #1007091] Mon, 04 February 2013 07:13 Go to next message
Eclipse UserFriend
Hi there,

we are using eclipse link 2.4 and we are having some issues on @AttributeOverride that seems to be ignored when we are referring to an @Embedded reference.

Here our scenario:
Person person
|-- Address myAddress
|-- Address secondaryAddress

where:
Address
|-- Zip myZip
|-- Zip mySecondaryZip
|-- String name

Zip
|-- Country myCountry
|-- String zipCode

Country
|-- String description

Address, Zip and Country classes are declared as @Embeddable(). Person is an @Entity.

myAddress has the following JPA annotations:
    @Embedded()
@AttributeOverrides({ @AttributeOverride(column = @Column(name = "myaddress_name"), name = "name"),
        @AttributeOverride(column = @Column(name = "myaddress_myzip_zipcode"), name = "myZip.zipCode"),
        @AttributeOverride(column = @Column(name = "myaddress_myzip_mycountry_description"), name = "myZip.myCountry.description"),
        @AttributeOverride(column = @Column(name = "myaddress_mysecondaryzip_zipcode"), name = "mySecondaryZip.zipCode"),
        @AttributeOverride(column = @Column(name = "myaddress_mysecondaryzip_mycountry_description"), name = "mySecondaryZip.myCountry.description") })
private Address myAddress = null;



Using eclipseLink and postgresql the columns:

myaddress_myzip_zipcode
myaddress_myzip_mycountry_description

are not created in person table. The others are correctly created. We are using JPA 2.0 and postgresql 9.2. Why does it happen ? Am I missing something obvious ?
Is there a problem with a three level-nested path ?

Thanks
Re: @AttributeOverride ignored with @Embedded [message #1007354 is a reply to message #1007091] Tue, 05 February 2013 10:39 Go to previous message
Eclipse UserFriend
Seems like it could be a bug, please log a bug with a test case.
Previous Topic:Where to download MOXy 2.2 ?
Next Topic:dbws utils generated war file gives error : _dbws.DBWSProvider is not available
Goto Forum:
  


Current Time: Sun Jul 13 12:02:49 EDT 2025

Powered by FUDForum. Page generated in 0.04160 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top