DECIMAL/NUMERIC fields rounded into TFloatField
Posted: Sat 12 Jul 2014 12:12
Hello,
I have tried to use UniDac with default settings and decimal values in order to view the limit over size of the decimal fields.
I have created on Firebird 2.5 this table:
CREATE TABLE TESTNUM
(
ID INTEGER NOT NULL,
NUM DECIMAL( 10, 2),
FLT DOUBLE PRECISION,
CONSTRAINT PK_TESTNUM PRIMARY KEY (ID)
);
Delphi XE6 + Unidac 5.39 create fields:
UniQuery1ID: TIntegerField;
UniQuery1NUM: TFloatField;
UniQuery1FLT: TFloatField;
When I edit on dbgrid or in TDBEdit the field NUM is automatically truncated of 2 decimal digits.
If I try to edit the field FLT it doesn’t limit the decimal digits.
Is it my impression but UniDac recognize the correct precision from DDL and automatically rounds the DECIMAL/NUMERIC fields?
If it is true, what is the round mode that you use?
If it is true, where can I find more information about this topic in the documentation?
If it is true, is it the same system with the other databases?
Thank you
Alessandro Savoiardo
I have tried to use UniDac with default settings and decimal values in order to view the limit over size of the decimal fields.
I have created on Firebird 2.5 this table:
CREATE TABLE TESTNUM
(
ID INTEGER NOT NULL,
NUM DECIMAL( 10, 2),
FLT DOUBLE PRECISION,
CONSTRAINT PK_TESTNUM PRIMARY KEY (ID)
);
Delphi XE6 + Unidac 5.39 create fields:
UniQuery1ID: TIntegerField;
UniQuery1NUM: TFloatField;
UniQuery1FLT: TFloatField;
When I edit on dbgrid or in TDBEdit the field NUM is automatically truncated of 2 decimal digits.
If I try to edit the field FLT it doesn’t limit the decimal digits.
Is it my impression but UniDac recognize the correct precision from DDL and automatically rounds the DECIMAL/NUMERIC fields?
If it is true, what is the round mode that you use?
If it is true, where can I find more information about this topic in the documentation?
If it is true, is it the same system with the other databases?
Thank you
Alessandro Savoiardo