Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2000 Forums
 SQL Server Administration (2000)
 SQL Server 7.0

Author  Topic 

AskSQLTeam
Ask SQLTeam Question

0 Posts

Posted - 2003-01-06 : 09:45:01
Basant writes "I'm using SQL Server 7.0. I've deleted log file with LDF extension of my database by mistake. I tried to retrive data but database's status became as suspected database. Now how can i get that database in normal status without log file? please show me the way to retrive all data of my database"

Merkin
Funky Drop Bear Fearing SQL Dude!

4970 Posts

Posted - 2003-01-06 : 17:08:08
Restore your backups.

You DO have backups don't you ?

Damian
Go to Top of Page

KnooKie
Aged Yak Warrior

623 Posts

Posted - 2003-01-07 : 07:24:59
If you want to just recover a suspect database you can use the following....

WARNING: be careful doing this

Use Damian's method if you have backups to hand which i'm sure you DO right !?!?


use master
go
sp_configure "allow updates", 1
reconfigure with override
go
update sysdatabases
set status = status - 256
where name = "database name"
and status & 256 = 256
go
sp_configure "allow updates", 0
reconfigure
go
checkpoint
go
shutdown
go

===========
Paul
Go to Top of Page
   

- Advertisement -