Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » EclipseLink » Problem with @DiscriminatorColumn(discriminatorType=DiscriminatorType.CHAR,)
Problem with @DiscriminatorColumn(discriminatorType=DiscriminatorType.CHAR,) [message #649021] Mon, 17 January 2011 10:09 Go to next message
Massimo Ugues is currently offline Massimo UguesFriend
Messages: 10
Registered: January 2011
Junior Member
Hallo all.
As described in this thread http:// stackoverflow.com/questions/4706102/jpa-discriminator-column -problem
I have a problem with the @DiscriminatorColumn.
On DB the discriminator column is CHAR(2) and it contains data on 1 char (e.g. 1,2,3,4,A).

If I model the@DiscriminatorValue("1") like this I get no data (even if the data is present on DB).

If I model the@DiscriminatorValue("1 ") like this with a space I get [EclipseLink-43] Missing class for indicator field value [1] of type [class java.lang.String].

If I change the column on DB and set to CHAR(1) all works great, but I have a legacy DB and I cannot make this change.

Is it possible to make some workaround? I need to say to eclipselink to make a trim when it handles that columns, or something similar.

Any idea?
kind regards
Massimo
Re: Problem with @DiscriminatorColumn(discriminatorType=DiscriminatorType.CHAR,) [message #649079 is a reply to message #649021] Mon, 17 January 2011 14:44 Go to previous message
James Sutherland is currently offline James SutherlandFriend
Messages: 1939
Registered: July 2009
Location: Ottawa, Canada
Senior Member

Responded on stack overflow.


James : Wiki : Book : Blog : Twitter
Previous Topic:Does EclipseLink support OracleXADataSource?
Next Topic:problem using DynamicJAXBContextFactory with xs:base64Binary
Goto Forum:
  


Current Time: Sat Apr 20 01:36:13 GMT 2024

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

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

Back to the top