TDBGrid + MySQL lazarus / 16-Databases ---------------------------------------------------------------------- oraitecamonyes · 2009-08-25 09:47 Hello ppl, i have a tdbgrid that receives data from a MySQL db. the dbgrid is populated fine, but when i press the scroll bar for a while i get an error: Quote"4294967295" is an invalid integer 1) Why does this happens and how can i avoid it?? 2) How can i get the total reccords of the MySQL table when the dbgrid is populated?? because i get the idea that the dbgrid is only loading 10 reccords at a time (i get 10 when i do this: Code: [Select]dbgrid1.DataSource.DataSet.RecordCount) Many thx ---------------------------------------------------------------------- Loesje · 2009-08-25 16:04 First issue is because you probably have some 'strange' value in your database, try to isolate it. Second issue us because PacketRecords is set to 10 by default. To avoid loading in the complete dataset when only the first records are used. Recordcount gives the amount of cached(read) records, not the total amount. Using PacketRecords:=-1 will load the complete dataset at once ---------------------------------------------------------------------- oraitecamonyes · 2009-08-30 08:50 Thx for your help Loesje. Quote from: Loesje on August 25, 2009, 06:04:23 pmFirst issue is because you probably have some 'strange' value in your database, try to isolate it. The strange is that the error first appears on the row number 121. I deleted this row and the error still pops up in the same row (that was now replaced with the old 122). I even tried to delete some rows before and after 121 and i ALLWAYS get the error on the row 121 no matter what data is in it!!! i also get the error in other rows after 121 (158, 216, 287, 289, 331, 343, etc...) I have no idea whats going on