This morning when I open SSMS, it turns out the error saying that could not connect to the server.
It's strange since yesterday it worked fine, and i just remember that the only modification is my colleage had taken one of the databases OFFLINE.
Finally i understand that the database he took offline is the default database, and in this case, the server is not accessible any more. The solution is trying to change the default database to master on this server, using the following cmd.
C:\> sqlcmd -E -d master
1> ALTER LOGIN [BUILTIN\Administrators] WITH
DEFAULT_DATABASE=master
2> GO
Then it works perfectly. :)
来自 “ ITPUB博客 ” ,链接:http://blog.itpub.net/12374161/viewspace-600592/,如需转载,请注明出处,否则将追究法律责任。
转载于:http://blog.itpub.net/12374161/viewspace-600592/