When
I try to run DBCC repair I get the below the errors .Database needs to
From Enterprise Manager:
DBCC CHECKTABLE('Person.Address', REPAIR_REBUILD )
Msg
7919, Level 16, State 3, Line 1
Repair statement not processed.
Database needs to be in single user mode.
The
correct way to run a DBCC CHECKDB or DBCC CHECKTABLE statement with valid
REPAIR options is to start SQL Server normally and then explicitly set the
database in single user mode. You can do this from either the Enterprise
Manager or the Query Analyzer.
When
single user mode set to true only one user can connect to the server.
From Enterprise Manager:
- Right-click the database name, and then click Properties.
- In the Properties dialog box, click Options.
- Select the single user option, and then click OK.
Run
DBCC command CHECKDB:
DBCC CHECKTABLE('Person.Address', REPAIR_REBUILD )
Comments
Post a Comment