Hi Ransome.
>How to write a routine to reindex the tables?? Is there a method firstly delete the tag files and regenerate a new set of index files??
Instead of creating this from scratch, take a look at Stonefield Database Toolkit (SDT):
www.stonefield.com.
Doug