MySQL and Numeric Formating lazarus / 16-Databases ---------------------------------------------------------------------- mirce.vladimirov · 2012-11-13 11:21 This is already solved, I'm posting this here in hope that this could help if anybody had the same issue and to aknowledge all newbies in Databases to use DOUBLE to express precision. Not FLOAT, not DECIMAL   but DOUBLE. I'm using Lazarus 1.0.2 and MySQL. Numeric type for expresing precision in my tables are set to 'DECIMAL(20,8)'. this is how i was showing my decimal numbers In previous versions of Lazarus (0.9.*): Code: [Select]TFloatField(SQLQuery1.FieldByName('za_naplata')).DisplayFormat := '0.00;-0.00;#.##'; I put this code straight after the sqlquery1.open and it was giving correct display, for example a value from the table 1.00 was displayed 1.00 in my DBGrids, and the value 1.23 was displayed 1.23, and if it was a negative number it was again displayed correctly. Everything was good until i switched to Lazarus 1.0.2, now this code does not work as expected: value of 1.00 is shown as 1 (no decimal places at all) while 1.23 is 1.23 (which is OK). Truncated decimal places (even when there are all zeroes after the decimal point)  are not wanted in many reports. The good thing is that I found the solution to this : I only modified the variable type in MySQL from DECIMAL(20,8) to DOUBLE and it work as it was used to work before, this way it shows correct values according to the formating command above. ---------------------------------------------------------------------- BigChimp · 2012-11-13 12:17 As long as clients using your database applications can live with any changes in precision generated by changing from DECIMAL to DOUBLE...?!?!?! Seems to be like formatting DECIMAL numbers should be possible... Were you using FPC 2.6 with both Laz 0.9.* and 1.0.2? Smells like it could be a bug to me but that will need to be confirmed - have never used TFloatFIeld