Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Corrupted or Locked Table
Message
De
12/01/2001 18:27:09
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Base de données, Tables, Vues, Index et syntaxe SQL
Divers
Thread ID:
00462627
Message ID:
00463279
Vues:
19
>Most of us have seen this at one time or another, especially under your circumstances: power loss or a workstation rebooted in the middle of updating data. The record count, which is stored in the table's header, is incorrect. I use a tool called Stonefield Database Toolkit to fix this problem, but there are others. SDT will go in and fix the record count in the table header.
>
>The best thing you can do is get UPSes on your workstations to prevent the power loss.
>
>>problem: table will not accept new records
>>
>>fix: copy table to another location
>> zap and pack the table
>> append records from the copied table
>>
>>The table works fine again...
>>
>>
>>
>>This type of corruption usually can be linked with some type of power loss or catastrophy on a workstation with files open.
>>
>>
>>If a file is corrupted in this way, it does not seem to return errors when running transactions such as:
>>
>>
>>local jrollback
>>jrollback=.f.
>>
>>BEGIN TRANS
>>
>> do stuff...
>>
>>if !tableupdate(.t.,.t.,'table')
>> jrollback=.t.
>>endif
>>
>>
>>if jrollback=.t.
>> ROLLBACK
>>else
>> END TRANS
>>endif
>>
>>
>>The transaction thinks that everything is fine and the tableupdate succeeds with no problems while no record is added to the table.
>>
>>I have seen this happen a small number of times. Has anyone else had experience with this?

Exactly the problem...

I have SDT but for some reason, did not think repair would fix...

Thanks for the comments.
Thanks,

Stacy



Black Mountain Software, Inc.
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform