Subject | Re: [IBO] expecting: Currency actual: BCD |
---|---|
Author | Geoff Worboys |
Post date | 2003-09-04T23:49:02Z |
> ..Type mismatch for field 'AnnualIncome', expecting:There is no longer any TIBOBCDField, you just use TBCDField.
> Currency actual: BCD
> I have defined AnnualIncome in the database as a
> Decimal(15,4).
> Is it possible to use TCurrencyField with IBO or do I
> need to switch to TIBOBCDField?
And yes, scaled integer types (DECIMAL and NUMERIC database
fields) will be typed as BCD.
The VCL "TCurrencyField" has nothing to do with the Delphi
"currency" data type - despite what it looks like.
TCurrencyField is expecting a floating point value not an
exact value. BCD implements internally as the "currency"
data type to ensure that exact values like NUMERIC and
DECIMAL behave consistently.
--
Geoff Worboys
Telesis Computing