Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Index problems 1

Status
Not open for further replies.

villan60

Technical User
Jul 5, 2001
23
ZA
I am importing a text file using a file spec. When creating a file spec in Access there is an option to specify for each field whether it should be indexed or not. I specify that none of them should be indexed, and yet when the file is imported it ends up with at least 3 indexes. So I loop through the index collection to delete each one... but it deletes all the indexes except one!

any ideas on what the heck is going on?

thanks
dax
 
Check Tools > Options > Tables/Queries tab > AutoIndex on Import/Create. That list of values that you see will cause automatic creation of an index for each field containing one of the values in its name. Get rid of that list.

If that doesn't work, I'd also make sure that Perform Name AutoCorrect is unchecked on the General tab.
 
Excellent.. thank you very much the AutoIndex thing was def the problem... any ideas on the second part of my question?
where my loop through the index collection is not deleting all the indexes.. here is the code I use

For Each Ix In td.Indexes
td.Indexes.Delete Ix.Name
Next Ix

thanks
dax

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top