Subject Re: [IBO] Rounding problems
Author Andreas Pohl
This my udf using in Delphi as well in Interbase:

function RoundPropper(var Value: Double): Double;
var z:extended;typ:Integer;
begin
if value<0 then typ:=-1 else typ:=1;
z:=abs(100*value);
if frac(z)>=0.5 then result:=typ*(int(z)+1)/100 else
result:=typ*int(z)/100;
end;

Mit freundlichem Gruss & Best Regards

Andreas Pohl
apohl@...
www.ibp-consult.com

I do this in delphi5 not through SQL