Cannot bring db "online" after taking offline

1

So, I took MS SQL Server DB offline. Now I am trying to bring it online and get error:

TITLE: Microsoft.SqlServer.Smo

Set offline failed for Database 'zzz'.

For help, click: https://go.microsoft.com/fwlink?ProdName=Microsoft_SQL_Server&ProdVer=16.100.46041.41_(SMO-master-A)&EvtSrc=Microsoft.SqlServer.Management.Smo.ExceptionTemplates.FailedOperationExceptionText&EvtID=Set_offline+Database&LinkId=20476


ADDITIONAL INFORMATION:

An exception occurred while executing a Transact-SQL statement or batch. (Microsoft.SqlServer.ConnectionInfo)

User does not have permission to alter database 'zzz', the database does not exist, or the database is not in a state that allows access checks.
ALTER DATABASE statement failed. (Microsoft SQL Server, Error: 5011)

katit2
已提問 3 年前檢視次數 698 次
2 個答案
1

Found. Should run special command, SSMS won't do:

EXEC rdsadmin.dbo.rds_set_database_online <Name of database>

katit2
已回答 3 年前
0

Thanks for posting your fix! worked for me

Luke
已回答 3 個月前

您尚未登入。 登入 去張貼答案。

一個好的回答可以清楚地回答問題並提供建設性的意見回饋,同時有助於提問者的專業成長。

回答問題指南