>After I read the mskb #
814131 I am concerned about the repair method recommended there. In summary, when the header record count is not matching the physical number of records in the table, the method described in the mskb removes records from the table.
>This, from what I see, could have a disastrous result. What if a header of a table with 100,000 records gets corrupted and the record count in the header changes to 5. Then the method describe in the msft article will remove almost all records from the table.
>
>Why don't they come up with a method to update the record count in the header of the table?
>
>Am I missing something or the recommendations in this article are very misleading?
Non-MS solutions try to update header reccount as you suggest:) However they too can't do anything if 100000 records table current size indicates table might have 5 at most. Check fox.wikis. I remember I posted code there. Pseudocode is like this:
readReccountInHeader
readRecSizeInHeader
readHeaderSize
if FileSize <> HeaderSize + (ReccountInHeader * RecSizeInHeader)
{
calculateReccountFromFileSize
WriteToHeader
}
PS: In old times fchsize() was also usefull and you might have a chance to recover more (up to allocated cluster boundary).
Cetin