db-jdo-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Craig Russell <Craig.Russ...@Sun.COM>
Subject Re: svn commit: r224397 - in /incubator/jdo/trunk/tck20/test/sql/derby: applicationidentity/schema.sql datastoreidentity/schema.sql
Date Mon, 25 Jul 2005 16:05:56 GMT
Hi Michael,

The change was deliberate. Notice that there were two column types  
for char and Character, and Michelle and I changed the CHAR(1) to  
INTEGER instead of the other way 'round.

For portability, INTEGER is better, as one the AllTypes data includes  
the entire range of CHAR values from 0..65535. Even though Derby can  
handle this with a CHAR(1) it will be better to have a more portable  
type.

For other tests, where there are a limited set of possible values, we  
chose CHAR(1) as we think this is portable to any database.

The philosophy is that we would like to have as little change as  
possible among the database mapping and schema, and only where there  
is a real incompatibility have to change.

Craig

On Jul 25, 2005, at 3:20 AM, Michael Watzek wrote:

> Hi Craig,
>
> I noticed that you changed the type of column ALLTYPES.CHARACTERVAL  
> from
> CHAR(1) to INTEGER. Did you check in this change accidently or
> intentionally? In the latter case, I propose to change the type of  
> other CHAR(1) columns also (except for those which are mapped by  
> boolean fields):
>
> - PrimitiveTypes.charNotNull
> - PrimitiveTypes.charNull
>
> Note, that the type of these columns is CHAR which defaults to CHAR 
> (1).
>
> Regards,
> Michael
>
> clr@apache.org wrote:
>
>> Author: clr
>> Date: Fri Jul 22 13:57:22 2005
>> New Revision: 224397
>> URL: http://svn.apache.org/viewcvs?rev=224397&view=rev
>> Log:
>> change type of char column to INTEGER to accommodate 65535
>> Modified:
>>     incubator/jdo/trunk/tck20/test/sql/derby/applicationidentity/ 
>> schema.sql
>>     incubator/jdo/trunk/tck20/test/sql/derby/datastoreidentity/ 
>> schema.sql
>> Modified: incubator/jdo/trunk/tck20/test/sql/derby/ 
>> applicationidentity/schema.sql
>> URL: http://svn.apache.org/viewcvs/incubator/jdo/trunk/tck20/test/ 
>> sql/derby/applicationidentity/schema.sql? 
>> rev=224397&r1=224396&r2=224397&view=diff
>> ===================================================================== 
>> =========
>> --- incubator/jdo/trunk/tck20/test/sql/derby/applicationidentity/ 
>> schema.sql (original)
>> +++ incubator/jdo/trunk/tck20/test/sql/derby/applicationidentity/ 
>> schema.sql Fri Jul 22 13:57:22 2005
>> @@ -868,7 +868,7 @@
>>      PRIMITIVESHORT SMALLINT,
>>      BOOLEANVAL CHAR(1) CHECK (BOOLEANVAL IN ('Y','N')),
>>      BYTEVAL SMALLINT,
>> -    CHARACTERVAL CHAR(1),
>> +    CHARACTERVAL INTEGER,
>>      DOUBLEVAL DOUBLE,
>>      FLOATVAL FLOAT,
>>      INTEGERVAL INTEGER,
>> Modified: incubator/jdo/trunk/tck20/test/sql/derby/ 
>> datastoreidentity/schema.sql
>> URL: http://svn.apache.org/viewcvs/incubator/jdo/trunk/tck20/test/ 
>> sql/derby/datastoreidentity/schema.sql? 
>> rev=224397&r1=224396&r2=224397&view=diff
>> ===================================================================== 
>> =========
>> --- incubator/jdo/trunk/tck20/test/sql/derby/datastoreidentity/ 
>> schema.sql (original)
>> +++ incubator/jdo/trunk/tck20/test/sql/derby/datastoreidentity/ 
>> schema.sql Fri Jul 22 13:57:22 2005
>> @@ -817,7 +817,7 @@
>>      PRIMITIVESHORT SMALLINT,
>>      BOOLEANVAL CHAR(1)CHECK (BOOLEANVAL IN ('Y','N')),
>>      BYTEVAL SMALLINT,
>> -    CHARACTERVAL CHAR(1),
>> +    CHARACTERVAL INTEGER,
>>      DOUBLEVAL DOUBLE,
>>      FLOATVAL FLOAT,
>>      INTEGERVAL INTEGER,
>>
>
>
> -- 
> -------------------------------------------------------------------
> Michael Watzek                  Tech@Spree Engineering GmbH
> mailto:mwa.tech@spree.de        Buelowstr. 66
> Tel.:  ++49/30/235 520 36       10783 Berlin - Germany
> Fax.:  ++49/30/217 520 12       http://www.spree.de/
> -------------------------------------------------------------------
>
>

Craig Russell
Architect, Sun Java Enterprise System http://java.sun.com/products/jdo
408 276-5638 mailto:Craig.Russell@sun.com
P.S. A good JDO? O, Gasp!


Mime
View raw message