3.2.2:
Using SQLServer 2000
Hey Ho,
Am trying to use the updateSchema tool to.... update my schema.
Taking the following definition
Code:
<property name="OpenPrice" precision="15" scale="6"/>
Update schema runs fine but creates the column with a datatype of float. Being as floats are approximate numbers only and should be used as the storage type of last resort (especially with financial systems), I was hoping to see it be stored as numeric(15,6).
Seems the only way to do this is to define the entry as:
Code:
<property name="OpenPrice">
<column name="OpenPrice" sql-type="numeric(15,6)"/>
</property>
The overhead comes here in having to create the column name mapping twice along with the nested <column...> entry (picky aint I?)
Twas my vague hope, that having a pojo with a Double type and specifying precsion and scale would create the table structure using a more precise storage value that a float.
Am I barking up the wrong tree with the way I'm going about this?
tia