db-jdo-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Andy Jefferson <a...@jpox.org>
Subject JIRA JDO-68
Date Sun, 31 Jul 2005 17:48:57 GMT
The issue about "A truncation error was encountered trying to shrink CHAR 
'65535' to length 1" should now be fixed with latest JPOX. JPOX CVS now uses 
default "jdbc-type" as per the most recent JDO spec. In particular for this 
error, when the java type is Character/char the jdbc-type chosen will be 
CHAR(1) (where the RDBMS supports it, which Derby does).

Test errors/failures previously were
61 for application-id, 60 for datastore-id. 

Now we have
51 for application-id, 46 for datastore-id.

and moreover, of the remaining errors there are 15 for application-id, and 11 
for datastore-id giving "SQL Exception: Invalid character string format for 
type INTEGER". This occurs where the schema has been defined with an INTEGER 
column to represent a Character/char(/String) java type (maybe to allow for 
previous JPOX behaviour) and implies that the schema needs some updates to 
match the default jdbc-type expected by the JDO2 spec (and now also by JPOX).

Schema where column is INTEGER but should be CHAR(1)
FieldsOfCharacter : table FIELDSOFCHARACTER has INTEGER columns
FieldsOfPrimitivechar : table FIELDSOFPRIMITIVECHAR has INTEGER columns

Schema where column is INTEGER but should be VARCHAR(...)
HashMapStringKeyCollections, HashMapStringValueCollections, 
MapStringKeyCollections, MapStringValueCollections, 
TreeMapStringKeyCollections, TreeMapStringValueCollections : join tables have 
the key as INTEGER instead of VARCHAR

There may be others of the same nature that I've not listed, just wanted to 
give a head start on fixing the schema.

Also, this change may affect other JIRA issues, but sadly 
"http://issues.apache.org" is about as unresponsive a server as I've ever 
come across, so we'll have to leave that for others to work out ;-)


View raw message