If you’re using SQL Server Management Studio Express under Windows Vista and see either of these errors:
CREATE DATABASE permission denied in database 'master'
or
The database [Name] is not accessible. (Microsoft.SqlServer.Express.ObjectExplorer)
Here’s the fix:
- Close SQL Server Management Studio Express
- Open your start menu and locate that program.
- Right-click on the Management Studio and choose ‘Run as Administrator’
- Fixed!
I swear the simplest solutions can be the hardest to find – hopefully this saves someone (or my forgetful self!) some aggravation.