Compact on close drops several indexes

HartJF

Registered User.
Local time
Today, 11:15
Joined
Jul 23, 2010
Messages
34
I cannot cause a database to refrain from dropping several table indices during a Compact on Close operation. I am running Access 2010 under Windows xp.

I have created a database that merges data in a linked text file with data in a linked database, appending the results in a local table. The database has the Compact on Close option set. The table has 27 indices (because most of the fields either are coded or are potential select or sort fields) and nearly 1½ million records.

I run a delete query to clear the contents of the table, I close (and compact) the database, I reopen the database, and I run the append query. The indices in the target table are intact. I close (and compact) the database again; when I reopen the database, indices are missing -- sometimes about 10, other times nearly two dozen!

This table is linked to a larger system, which contains code to run the sequence outlined above. Whether run manually or in code, as stand-alone or as a component, indices are dropped. When I close the database with the table containing no records, the indices are not affected. After appending records, but before closing, the database contains 1.66GB. The drive on which the database resides has 42GB free.

As suggested with regard to a number of other unexplainable issues, I have created a new database and imported all objects from the original database. The results persist. The larger system performs accurately without the indices, but the performance against a table this massive is horrible.

I have spent two days on this merry-go-round, so I seek your help so that I can accomplish something. While awaiting responses, I will create a new database, import the non-offending objects, but manually re-create the table with its indices.

I am a functional user to whom IS does not want to grant access to SQL Server, so I have to use such tools as I have access. (pun intended... it's Friday)
 
This is as marvelous a tool as it is unfortunate a need. Is this an issue of which Microsoft is unaware? Is it limited to a specific environment, or do many developers commonly encounter it? I love Access, but it surely is inclined to jump up and bite us!

Thank you for a wonderful assist!
 
Databases are limited to 2g in size and Indexes take up a fair amount of room for such a large table. Perhaps Access decided to drop them due to lack of space. Is it always specific indexes that are dropped? For example, the last 10 or first 10.
 
It tops out at 1.66GB before the Compact on Close. It did touch 2GB, but that's why I split components of the base system into pieces. It once dropped the last 10, another time the last 14, another time the last 26. It's inconsistent. That's what so wacky!

I've created the Indexer database that Bob suggested; I'll try to utilize it on Monday.
 
Is the 1.66 size AFTER you compact or before? If it is after, then you need to monitor the database size as you are adding data and building indexes.
 
Before I compact, the database is 1.66GB; afterwards, it is 1.19GB
 
Then you need to open a problem report with Microsoft. They charge for problem solving so be prepared with a credit card. But, if it turns out to be a bug, they will refund your money.
 

Users who are viewing this thread

Back
Top Bottom