Board index » delphi » TAggregate Field 'AsFloat' doesn't work, why?

TAggregate Field 'AsFloat' doesn't work, why?

Hi,
I have a calculated field in a Interbase database.
I've setup a persistent field to map to that - it's an Aggregate type to get
the Sum.

I then say  Value := SumOfAmount.AsFloat;

and it compiles, but at run time it says cannot return result as Float.

Why?

thanks,
John Scalco

 

Re:TAggregate Field 'AsFloat' doesn't work, why?


What version of InterBase? What is the data type of the InterBase field?

--
Bill

Re:TAggregate Field 'AsFloat' doesn't work, why?


Hi,
Thanks for the response.

The version of InterBase is the 6.0  (free one I believe).
The type was a Number, which is set to hold a percent.  95.22 for example.

A couple of other people in the office (all running same database and D5
Enterprise) have the same problem. We have come up with work arounds, but it
bothers me enough to ask if anyone has heard of such a thing - which I would
think anyone who has used Aggregates has .....

thanks,
John Scalco

"Bill Todd (TeamB)" <bill.nos...@dbginc.com> wrote in message
news:3b4a4dc2$1_1@dnews...

Quote
> What version of InterBase? What is the data type of the InterBase field?

> --
> Bill

Re:TAggregate Field 'AsFloat' doesn't work, why?


1) There is no data type in InterBase whose name is "number".
2) I don't understand what you mean by an aggregate data type.

You need to supply much more detailed information about what you are doing
to derive the value in this field, what components you are using to connect
to InterBase if we are going to be able to help you.

--
Bill

Other Threads