Rounding problem

Forum related to MS SQL Server

Moderators: gto, cipto_kh, EgonHugeist

Fresh Boarder
Fresh Boarder
Posts: 2
Joined: 06.10.2009, 04:53

Rounding problem

Postby irvinehing » 07.10.2009, 05:30

Hi all,

I'm using BCB6+ZeosDBO 6.1.5 to connect MSSQL (MSDE).
In the table, I set a field data type as real and value set as 24445.21

When I query from the table and display at DBGrid, the value always display 24445.20. After I set to 24445.25, the value display as 24445.30

Even I set the display format as #,##0.00, the value still display like 24445.30

But, if I using ADO, the value display like 24445.25, it's correct.

Anyone know what's problem?
You do not have the required permissions to view the files attached to this post.

User avatar
Zeos Project Manager
Zeos Project Manager
Posts: 2766
Joined: 20.09.2005, 15:28
Location: Brussels, Belgium

Postby mdaems » 09.10.2009, 20:41

As we're talking about ZeosDBO 6.1.5, I'm not really a fan of checking this myself, but this issue seems similar to the issue we had with fb precsion. The field being retrieved into a Float variable instead of a double.
What we changed there you can see here :

I hope this helps you a little...


Return to “MS SQL Server”

Who is online

Users browsing this forum: No registered users and 1 guest