473,761 Members | 2,410 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Access has detected corruption in this file

1 New Member
I face the below error message, when I attempt to mount an Access database
"Microsoft Access has detected corruption in this file. To try to repair the corruption, first make a backup copy of the file. Then, on the Tools menu, point to Database Utilities and click Compact and Repair Database. If you are currently trying to repair this corruption then you will need to recreate this file or restore it from a previous backup."

What can I do resolve the error?
Oct 19 '09 #1
3 3833
missinglinq
3,532 Recognized Expert Specialist
Oh, let's see: First make a backup copy of the file. Then, on the Tools menu, point to Database Utilities and click Compact and Repair Database ?

Linq ;0)>
Oct 19 '09 #2
NeoPa
32,572 Recognized Expert Moderator MVP
Martin, you omitted to explain whether or not you had already followed the instructions posted in the error message.

If you have tried this already then you need to tell us that, as well as what resulted from it. We can move on from there, but only if we know what's happening.
Oct 19 '09 #3
samjoseph74
2 New Member
To resolve the above error message and access the data stored in the database, you will need to follow these steps:

1. Create a blank database = “C:\ Recover_db.mdb”
2. Close and exit.
3. Create another blank database and navigate to Modules Tab
4. Click on New and Paste the code provided below:
Expand|Select|Wrap|Line Numbers
  1. Dim db As DAO.Database
  2.  
  3. Set db = DAO.OpenDatabase("C:Corrupt_db.mdb")
  4.  
  5. Dim xtable As TableDef
  6.  
  7. For Each xtable In db.TableDefs
  8.  
  9. If Mid(xtable.Name, 1, 4) <> "MSys" Then
  10.  
  11. rSQL = "SELECT * INTO [" & xtable.Name & "] IN " & _
  12.  
  13. "'C:Recover_db.mdb'" & _
  14.  
  15. " FROM [" & xtable.Name & "]"
  16.  
  17. db.Execute rSQL
  18.  
  19. End If
  20.  
  21. Next xtable
  22.  
  23. MsgBox "Process Complete."
  24.  
  25. End Function
5. Go to Menu Tools, select References, and scroll down and Select "Microsoft DAO 3.6 Object Library"
6. Click OK
7. In Module Window Click on Recover_db() Function
8. Check database file names, after proper setup and press the F5 button
9. Tables and data from corrupt database is recovered to new database

Another way to resolve the problem (as stated in the error message) is by using an inbuilt repair utility known as “Compact and Repair.” However, if the inbuilt repair utility fails to repair the database, then you need to use advanced Access Repair application as Stellar Phoenix Access Recovery Software.
Oct 20 '09 #4

Sign in to post your reply or Sign up for a free account.

Similar topics

13
13352
by: Simon Bailey | last post by:
I am a newcomer to databases and am not sure which DBMS to use. I have a very simplified knowledge of databases overall. I would very much appreciate a (simplifed) message explaining the advantages and disadvantages of both programs. Many Thanks Simon
6
4752
by: Peter Frost | last post by:
Please help I don't know if this is possible but what I would really like to do is to use On Error Goto to capture the code that is being executed when an error occurs. Any help would be much appreciated. Thanks in advance
7
1918
by: Doug Vogel | last post by:
Hi All - I have a client for whom I developed an Access 2000 database. The database is split into 2 files - front-end (forms, queries, reports), and back-end (tables). An .mde file has been made for the front end file. Recently, they have been noticing some "problems" with the system. Basically this system creates invoices for their customers. They have been noticing that some of the invoices are now "wrong", specifically
4
4612
by: DFS | last post by:
" has detected corruption in this file. To try to repair the corruption, first make a backup copy of the file. Then, on the Tools menu, point to Database Utilities and click Compact and Repair database. If you are currently trying to repair this corruption then you will need to recreate this file or restore it from a previous backup." I think it's my usage of the Excel 9.0 object library that's causing the problem, but I can't be...
1
1346
by: Matthew | last post by:
Hello Access gurus, I'm helping out a friend who's a small business owner. The software he uses to run his shop uses an Access backend. We recently had some huge headaches w/DB corruption. We had to send the main mdb file back to the vendor, who had to send it to an outside company in order to get it fixed. When they did this, we were told that it could be days until we'd get it back. We had a backup that was 3 days old at that...
47
4543
by: ship | last post by:
Hi We need some advice: We are thinking of upgrading our Access database from Access 2000 to Access 2004. How stable is MS Office 2003? (particularly Access 2003). We are just a small company and this is a big decision for us(!) It's not just the money it's committing to an new version of Access!
18
7344
by: Andre Laplume via AccessMonster.com | last post by:
I have inherited a bunch of dbs which are are shared among a small group in my dept. We typically use the dbs to write queries to extract data, usually dumping it into Excel. Most dbs originated in MsAccess 97 or prior and have been converted to 2003. On occassion user 1 will open a db. When user 2 opens the db it will not let user 2 modify macros and what not. I can understand this and realize we could split the db; it is not worth ...
13
2677
by: Owen Jenkins | last post by:
Following on from an earlier post... I can reliably corrupt a record by doing the following ... Open two separate but identical front ends on one PC each linking to the same back end. Edit a records in one front end and leave it unsaved. Edit the same record in the other front end and save the change. Save the change in the first front end - this pops up the Write Conflict message to which I click Save.
1
2945
by: mahiapkum | last post by:
hello all i have a code which looks fine when reviewed but when the application has a long run say for example of 2 days it gets exit, because of glibc error and the sample code is as follows: while (1) { if((kfp = kd_open(kd_filename, READ, NULL , INIT_YES))== NULL) { printf("%s: File not found ...\n", kd_filename); if (!forceflag) { sleep(5); ...
0
9522
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
10111
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
9948
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
9902
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
8770
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
7327
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5364
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
3
3446
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
2738
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.