We help IT Professionals succeed at work.
Get Started

Access DB Crashing on Compact

Last Modified: 2013-08-13
I have an Access 2007 database that averages about 1.2 GB (it fluctuates as it goes through weekly processing steps, so we compact it throughout the process).  The issue is that the database always crashes when I compact at a certain point in the processing.  Here's an overview of the process:
run queries and VB code via macro to update Table 1
compact database
run queries and VB code via macro to update Table 2
compact database
run queries and VB code via macro to update Table 3
attempt to compact database but it crashes

I suspect Table 3 to have some sort of corruption since the crash occurs after updating that table.  After Table 3 is updated I cannot import or export it between databases without a crash.  The only work-around I have found so far is to create (from scratch) an empty shell with the same design as Table 3, export the contents of Table 3 as a csv file (because it's 500K records), and import the contents of the csv file into the shell table.  After doing this I can compact the database sucessfully and proceed to the next processing steps.  However, the next week I experience the same behavior.

what would cause this and how do I resolve it?
Watch Question
President / Owner
Most Valuable Expert 2017
This problem has been solved!
Unlock 1 Answer and 6 Comments.
See Answer
Why Experts Exchange?

Experts Exchange always has the answer, or at the least points me in the correct direction! It is like having another employee that is extremely experienced.

Jim Murphy
Programmer at Smart IT Solutions

When asked, what has been your best career decision?

Deciding to stick with EE.

Mohamed Asif
Technical Department Head

Being involved with EE helped me to grow personally and professionally.

Carl Webster
CTP, Sr Infrastructure Consultant
Ask ANY Question

Connect with Certified Experts to gain insight and support on specific technology challenges including:

  • Troubleshooting
  • Research
  • Professional Opinions
Did You Know?

We've partnered with two important charities to provide clean water and computer science education to those who need it most. READ MORE