db-ddlutils-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Daniel López <D.Lo...@uib.es>
Subject Re: Additions to generated XML
Date Thu, 21 Feb 2008 07:39:53 GMT
Hi,

I don't have a list of databases that use radix, but a quick search says 
that Oracle and SQLServer have it and the Apache Derby JDBC driver also 
returns some value for it. HSQLDB on the other hand does not seem to 
have anything about it in the documentation... or MySQL, or Informix... 
not sure if it is too common. It seems that the usual values are 10 or 
2, implying that the length specified by the column is to be interpreted 
as "number of digits" or "number of bits" to store the value, but it 
does not seem to be too general.

We are using Oracle and we came across this attribute so we thought it 
was more widely used. But from this tiny research, it might not be 
worthy attacking it now.

Regarding the Oracle columns, when reading the DB we detected the Oracle 
version automatically, but I understand that introducing this vendor 
specific things into a general tool is not too elegant.

S!
D.

Thomas Dudziak escribió:
> Hi Daniel,
> 
...
>> We found out that the numerical columns had also an attribute for the
>> RADIX, usually radix is always 10 but it could be different if the colum
>> stores directly hexadecimal numbers (radix 16)... Unless for some
>> special cases, not taking into account the radix would not be a problem.
>> We haven't come across any column like that but just in case, we added
>> it ;).
> 
> Mhmm, interesting, do you know which databases support radix ?


>> Nothing fancy, just to take into account that a java.util.Date is better
>> stored as TIMESTAMP, only available in versions > Oracle 8.1.7, as DATE
>> would mean losing the milliseconds. I just saw a note in Torque on how
>> to handle that:
>> http://db.apache.org/torque/version-specific/database-howtos/oracle-howto.html
>> SO I guess that it is covered. We were using a previous version of
>> Torque were this was not being handled, so we had done it ourselves..
> 
> Yeah, just explicitly specify the platform to be oracle9 or oracle10
> and DdlUtils will use TIMESTAMP instead of DATE.


Mime
View raw message