1. Run an agent to remove the erased field's data from all documents.
FIELD oldField1 := @Unavailable; Select @ALL
2. Then, you need to remove the field from ALL forms and views; do a Design Synopsis to make sure.
3. When you delete a field on a form, always do it by clicking to the right of it and doing a backspace. You should get a prompt asking if you want to delete the field. If you just select the field and press delete, you get no prompt, and the field is not deleted from the UNK.
My experience has been that there are other ways to get the field "properly" deleted, but the key is that, if you are prompted if it's OK to delete the field, you did it properly; if you are NOT prompted, you did
not.
4. Then (and this is the one most often forgotten), if the db has a Full Text Index, you MUST DELETE IT BEFORE compacting the db.
5. Then compact the db.
The above steps work about 80-90% of the time.
If not, here's an optional step we'll call 2a, which you can do before steps 3 and 4 (also from Mark Darrah):
"You must now get rid of the field's "ghosts" from all the forms. There are several ways to do this.
a. Create a new blank form. Now take each of your existing forms in design mode, and copy and paste the entire form contents into the new blank form. Repeat for each form in the database. Then delete the old forms and rename the new ones. Be aware that although this is the easiest method, I have had problems with tab settings and hide-whens getting screwed up. Double check all settings when done. Also, you'll need to copy all your form events if any, and the window title formulas.
b. Another method is to add the field back into the form temporarily (just create a new field and name it as the old field). Now do the delete as described above by clicking to the right and doing a backspace. You should get the prompt."