DBGrid + Zeos do not show decimals lazarus / 16-Databases ---------------------------------------------------------------------- Pere · 2010-02-05 12:32 Sorry for my bad English. With Firebird 2.1 + ZQuery the DBgrid do not show the decimals. (20.43 show 20). I solved it manually adding (and formating) columns to DBGrid, but it is not a good solution if you use the same grid for different datasets. There is another solution to solve it automatically? Thanks, ---------------------------------------------------------------------- JD · 2010-02-05 17:00 Put the format string in the DisplayFormat property of the DbGrid column in your form. That way you don't need to format the column in your code. Be aware however that this format will apply to all datasets that are displayed using the DBGrid unless you change it manually again in your code. ---------------------------------------------------------------------- lazguy · 2010-09-01 15:59 It seems that Zeos have a bug when run on Linux. I have this problem also. If I am not wrong on Windows everything is Ok. (or if I am wrong) only the Delphi Version of Zeos is Ok. The problem is not only with DBGrid. ---------------------------------------------------------------------- garlar27 · 2010-09-01 18:01 I have the same decimals problem with TDbf and DBGrid. DBGrid in some cases show decimals in scientific format, some times shows 1 rounded decimal when it should show 2... I think the problem is in DBGrid. ---------------------------------------------------------------------- cpalx · 2010-09-02 17:18 try to change  "," decimal to "." decimal. believe me that is the error. ---------------------------------------------------------------------- guidoaerts · 2010-09-20 20:13 you can also change the displayformat property of the float-data-type fields  of an opened tztable or tzquery; that leaves your grid unaffected for other datasets guido ---------------------------------------------------------------------- Pere · 2010-10-18 08:06 I solved dinamically by:   ZQuery1.Active:= True;   with ZQuery1 do   begin    for i := 0 to FieldCount-1 do    begin     if Fields.FieldKind = fkData then if Fields.DataType =ftFloat then      TFloatField(Fields).DisplayFormat := '0.00';    end;   end; ---------------------------------------------------------------------- cpalx · 2010-10-19 01:43 good ...