Help with dbf database... lazarus / 16-Databases ---------------------------------------------------------------------- Robert W.B. · 2022-02-03 21:55 I try to do a dbf database but I have got an error message. Message "Unable to retreive field definition from dataset"  There are 2 items in dataset but after the errormessage there are 0 items left. They just vanished! What can I do to solve this? Thanks in Advance. Best regards Robert ---------------------------------------------------------------------- Lansdowne · 2022-02-04 09:22 You haven't given us much information about what you're trying to do or what code triggers this error. Does this error appear as soon as you start your program? Have you got some data controls that display the data even at design time?  If so, try switching that off (set Active to false for the tables in Object Inspector) and open them in your program/unit. (myTable.Open). If that's not it, we probably need to know more about your project. ---------------------------------------------------------------------- marcov · 2022-02-04 12:07 dbf has been a while, but IIRC items can have a "deleted" flag for deleted items to be removed by the next vacuum/pack. ---------------------------------------------------------------------- Thaddy · 2022-02-04 12:46 Quote from: marcov on February 04, 2022, 01:07:42 pmdbf has been a while, but IIRC items can have a "deleted" flag for deleted items to be removed by the next vacuum/pack. Correct. $2A means to be deleted $20 means active. First byte in a record. (@Marco Note that e.g. PerfectView - which used the .dbf format - did not strictly adhere to that, but I fixed it in the early'90's ) Note that the fpc version (Tdbf)  is much self-documenting sourcecode and reasonably complete. One can set the ShowDeleted property to un-hide or hide records marked for deletion. If the latter does not work, it may be that you have a corrupt file: disks with dBase tables on it tend to be very, very, very, very old... ---------------------------------------------------------------------- marcov · 2022-02-04 13:18 DBF as an authoritative db system is old yes. But it was used as a "message" and export database for quite a while after. Actually that is where I got most by dbf experience :-)