I had a laptop die HDD went dead which a running sql database was opened (in program) I had to have the hard drive recovered however all i got back was a bad database which has the torn page. All pro software seams to be able to read my database and fix if i pay the 399.00 for the software however i was hoping i could use the built in DBCC However it seams everything i try wont work so i am hoping for some help. Here is the error when I try to bring the database online Msg 945, Level 14, State 2, Line 1Database 'CompassDefaultDB' cannot be opened due to inaccessible files or insufficient memory or disk space. See the SQL Server errorlog for details.Msg 5069, Level 16, State 1, Line 1ALTER DATABASE statement failed.Msg 824, Level 24, State 2, Line 1SQL Server detected a logical consistency-based I/O error: incorrect checksum (expected: 0x20203e65; actual: 0x1f329010). It occurred during a read of page (1:9) in database ID 5 at offset 0x00000000012000 in file 'C:\Program Files\Microsoft SQL Server\MSSQL.2\MSSQL\Data\CompassDefaultDB_51120120410_data.mdf'. Additional messages in the SQL Server error log or system event log may provide more detail. This is a severe error condition that threatens database integrity and must be corrected immediately. Complete a full database consistency check (DBCC CHECKDB). This error can be caused by many factors; for more information, see SQL Server Books Online.
So Then I Try DBCC CHECKDB (CompassDefaultDB, REPAIR_ALLOW_DATA_LOSS) WITH NO_INFOMSGS;That give me Msg 945, Level 14, State 2, Line 1Database 'CompassDefaultDB' cannot be opened due to inaccessible files or insufficient memory or disk space. See the SQL Server errorlog for details.
So Then I Try ALTER DATABASE CompassDefaultDB SET EMERGENCY;Msg 824, Level 24, State 2, Line 1SQL Server detected a logical consistency-based I/O error: incorrect checksum (expected: 0x20203e65; actual: 0x1f329010). It occurred during a read of page (1:9) in database ID 5 at offset 0x00000000012000 in file 'C:\Program Files\Microsoft SQL Server\MSSQL.2\MSSQL\Data\CompassDefaultDB_51120120410_data.mdf'. Additional messages in the SQL Server error log or system event log may provide more detail. This is a severe error condition that threatens database integrity and must be corrected immediately. Complete a full database consistency check (DBCC CHECKDB). This error can be caused by many factors; for more information, see SQL Server Books Online.
Then DBCC CHECKDB (CompassDefaultDB, REPAIR_ALLOW_DATA_LOSS) WITH NO_INFOMSGS;Msg 922, Level 14, State 1, Line 1Database 'CompassDefaultDB' is being recovered. Waiting until recovery is finished.
It stays in this mode forever and does not seam to finish this database is only 2MB with like 17 Rows of data i am after. I can restart the sql server and repeat the same steps with the same results. Is there something i am doing wrong? any help is greatly appricated I do have the origional corrupted database and have tried to restore and repeat but with the same results I have also tried to bring up a database with the same name delete the mdf file and replace with me mdf file with the same basic results. There is no backup :( Thanks again for looking