Page 1 of 1

Is there any way to determine the scale of a number field?

Posted: Sat 27 Oct 2007 07:51
by Moehre
Hello!

I searched this forum and the internet without any solution, so I ask you as oracle experts:

In my application it is neccesarry to get the scale of numbers f.e. NUMBER(12,3) with 3 digits scale. I can access the precision of 12 in TDataset.FieldDefs[x].Precision but can not find any information about the 3 digits scale. Is there any way to get this information? And, by the way, why is TDataset.FieldDefs[x].Size = 0 ?? In my optinion, size should be 12 and precision 3 ...?

Thx
Moehre

Posted: Mon 29 Oct 2007 09:08
by Plash
You can use the GetFieldScale and GetFieldPrecision methods of TOraQuery to get precision and scale of a field. We'll consider possibility to fill in the Size property of TFieldDesc for NUMBER fields in either of the next ODAC versions.