Quoted table names in @Column(..., table = "\"Addresses\"") produces DescriptorE [message #1834755] |
Tue, 17 November 2020 12:30  |
Karsten Wutzke Messages: 124 Registered: July 2009 |
Senior Member |
|
|
Hello all.
I seem to have found an issue with EclipseLink using the following mapping:
@Entity
@Table(name = "\"Contacts\"")
@SecondaryTable(name = "\"Addresses\"", pkJoinColumns = @PrimaryKeyJoinColumn(name = "contact_id", referencedColumnName = "id"))
public class Contact implements Serializable
{
private static final long serialVersionUID = 1L;
@Id
@GeneratedValue(strategy = GenerationType.IDENTITY)
@Column
private Integer id;
@Basic
@Column(name = "country_code", table = "\"Addresses\"")
private String countryCode;
@Basic
@Column(name = "zip_code", table = "\"Addresses\"")
private String zipCode;
@Basic
@Column(name = "city_name", table = "\"Addresses\"")
private String cityName;
@Basic
@Column(name = "street_name", table = "\"Addresses\"")
private String streetName;
@Basic
@Column(name = "house_nbr", table = "\"Addresses\"")
private String houseNbr;
When deploying the app on WildFly, everything is fine. Requesting some page then throws a DescriptorException:
Exception [EclipseLink-93] (Eclipse Persistence Services - 2.7.7.v20200504-69f2c2b80d): org.eclipse.persistence.exceptions.DescriptorException
Exception Description: The table ["Addresses"] is not present in this descriptor.
Descriptor: RelationalDescriptor(net.bbstatstest.i286.entity.Contact --> [DatabaseTable(Contacts), DatabaseTable(Addresses)])
I placed the whole thing onto SO here: https://stackoverflow.com/questions/64868818/eclipselink-the-table-addresses-is-not-present-in-this-descriptor-descripto
Standard JPA quoting of table names should be supported here, right?
Is this a bug?
Karsten
[Updated on: Tue, 17 November 2020 16:10] Report message to a moderator
|
|
|
|
Powered by
FUDForum. Page generated in 0.02019 seconds