Fix the hardware issue and follow the below steps to delete and recreate the bad records
1) Record all recid values from error 3191.
2) Use the following code to find out the field name referred by field-num on error 450 or 3191.
FIND _file WHERE _file-num = "<table-num>".
FOR EACH _field OF _file where _field-rpos = <field-num-value>:
DISP _file._file-name _field._field-name.
END.
3) For each recid use the following code to export the fields that are not corrupted, by changing the <field-name> below to the ones found in step 2 .
OUTPUT TO VALUE(string(<recid>) + ".txt").
FIND <table-name> WHERE RECID(<table-name>) = <recid>.
EXPORT <table-name> EXCEPT <field-name>.
4) You can now delete the bad records using the command:
proutil dbname -C idxfix
You will be presented with a menu, select these options:
Menu Item 6. Delete one record and it's index entries.
It will then ask you to "Type the recid to delete."
It will then ask you to "Type the area for the recid(s)."
Repeat for each recid that is corrupt.
|