Recently I detached database from SQL Server 2000 Enterprise Manager. When I
try to attach it, I got a message: Error 9003: The LSN (8855:5583:1) passed
to log scan in database 'contacts' is invalid. I have SQL Server 2000 with
SP3 installed. All MDF and LDF files are present. Please help me to resolve
this problem.
Thank you
Igor A. Chechet
--
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://www.solidqualitylearning.com/
"Igor A. Chechet" <che...@etel.ru> wrote in message news:Or$BpoKcF...@TK2MSFTNGP09.phx.gbl...
1. Create Database with exact name and mdf-ldf files
2. Stop MSSQLSERVER service, replace created mdf file with original one
3. Start MSSQLSERVER service, the database will be in Suspend mode
4. From Query Analyzer (QA) execute script
use master
go
sp_configure 'allow updates', 1
reconfigure with override
go
5. From QA execute script
update sysdatabases set status= 32768 where name = '<db_name>'
6. Restart MSSQLSERVER service, the database will be in Emergency mode
7. Rebuild Log. From QA execute script
DBCC REBUILD_LOG('<db_name>', '<full name to new log file>'). You got a
message - Warning: The log for database '<db_name>' has been rebuilt.
8. From QA execute script
Use master
go
sp_configure 'allow updates', 0
Go
9. Clear from Enterprise Manager on database properties options tab Restrict
access checkbox
It works
Igor A. Chechet
--
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://www.solidqualitylearning.com/
"Igor A. Chechet" <che...@etel.ru> wrote in message news:OOU%233kMcF...@TK2MSFTNGP09.phx.gbl...