Hello all.
I have used the following T-SQL to restore a database:
restore database dbname
from db_device
with dbo_only,
norecovery,
stats,
move 'dbname_data' to 'd:\mssql7\data\dbname_data.mdf',
move 'dbname_log' to 'd:\mssql7\data\dbname_log.ldf'
Now, that it is restored, I cannot use it as I get an error message "Database cannot be opened. It is in the middle of a restore". I know that since I specified dbo_only, only the database owner can use it. However, I am logged in as "sa", the system administrator. I then do this command:
sp_dboption 'dbname', 'dbo only use only', 'false'
This is the error I get:
Database 'members' cannot be opened. It is in the middle of a restore. Checkpointing database that was changed.
Does anyone have any ideas how I can see the database again? Your help is greatly appreciated!
Thanks,
Steve S.
sms@hmbnet.com
I have used the following T-SQL to restore a database:
restore database dbname
from db_device
with dbo_only,
norecovery,
stats,
move 'dbname_data' to 'd:\mssql7\data\dbname_data.mdf',
move 'dbname_log' to 'd:\mssql7\data\dbname_log.ldf'
Now, that it is restored, I cannot use it as I get an error message "Database cannot be opened. It is in the middle of a restore". I know that since I specified dbo_only, only the database owner can use it. However, I am logged in as "sa", the system administrator. I then do this command:
sp_dboption 'dbname', 'dbo only use only', 'false'
This is the error I get:
Database 'members' cannot be opened. It is in the middle of a restore. Checkpointing database that was changed.
Does anyone have any ideas how I can see the database again? Your help is greatly appreciated!
Thanks,
Steve S.
sms@hmbnet.com