Browse Source

fcl-db: interbase: avoid conversions ->TBCD->double for parameters of other type than ftFmtBCD (f.e. ftBCD: Currency->TBCD->double)

git-svn-id: trunk@29180 -
lacak 10 years ago
parent
commit
690fc3e738
1 changed files with 1 additions and 1 deletions
  1. 1 1
      packages/fcl-db/src/sqldb/interbase/ibconnection.pp

+ 1 - 1
packages/fcl-db/src/sqldb/interbase/ibconnection.pp

@@ -1004,7 +1004,7 @@ begin
             if VSQLVar^.sqlscale = 0 then
               i := AParams[ParNr].AsInteger
             else
-              i := Round(BCDToDouble(AParams[ParNr].AsFMTBCD) * IntPower10(-VSQLVar^.sqlscale)); //*any number of digits
+              i := Round(AParams[ParNr].AsFloat * IntPower10(-VSQLVar^.sqlscale)); //*any number of digits
             Move(i, VSQLVar^.SQLData^, VSQLVar^.SQLLen);
           end;
         SQL_SHORT, SQL_BOOLEAN_INTERBASE :