Corrupt DB

ducker

across the pond
Local time
Today, 16:57
Joined
Jan 6, 2005
Messages
55
Ok,
I've seen this quite a few times and I've been unsuccessful in fully restoring the database after an error like this.

AC97
The database shows up that it needs to be repaired.
When I attempt to repair it I get the following error:

"Couldn't use Prospect 2.mdb. file already in use."

Yet checking on the server, no one has the database open at all.

One workaround I've done in the past has been to copy all objects out of the database in to a new database. Sometimes this works. Usually there is some loss of data as many times it's a corrupt table.

any other suggestions in how to solve this problem?

-m

ps. I made a few copies of the database, and one of them allows me to repair/compact it, and it's fine. This doesn't make sense to me at all. Why would a copy of a .mdb allow me to fix this issue where as the original one won't?
 
The computer of a previous user who was in the db that day still had a lock on the db. You need to ask all users of the db to reboot their PC to ensure the connection is broken. You can not see the connection but the db considers itself still attached to somebodies PC. That would explain why a copy can be repaired or compacted but not the original file. If the .ldb file is still visible then you can open it in Notepad.exe and view who's computers were in the db since the last time the mdb was successfully shut down.
 
hm, yet I looked at the .ldb and found nothing. And I checked on the File server and there were no open files there.

Something intersting... a number of "system tables" where all messed up after I repaired it. I ended up recreating the database. Dumping all created structures/data in to a new database. This worked.

Makes sense? Not entirely for me :D

-Mike
 
That is the advantage of importing all of the db objects [minus the system objects] into a new db for you can not fix a db once a system table is corrupt.

Have you tried the free Ject Compact Utility from Microsoft? If works great for repairing and compacting databases that have corrupted indexs. I have had a lot of success using Jet Compact to repair a db when I thought it was corrupted and Access could not repair itself.

Access 97: Updated Version of Microsoft Jet 3.5 Available for Download

Access 2000: Jet Compact Utility Available in Download Center

Access 2002: Jet Compact Utility Available in Download Center
 

Users who are viewing this thread

Back
Top Bottom