Click here to Skip to main content
15,881,413 members
Please Sign up or sign in to vote.
3.00/5 (1 vote)
CREATE DATABASE permission denied in database 'master'.
An attempt to attach an auto-named database for file c:\inetpub\wwwroot\Bug2Bug\App_Data\Books.mdf failed. A database with the same name exists, or specified file cannot be opened, or it is located on UNC share.


i don't what is this problem ?
i googled so much but no solution.
i got this error when i installed web setup in another pc which is created by me in vs2010, and sqlserver 2008 r2.

please help me
Posted
Updated 20-Nov-12 17:20pm
v2
Comments
ZurdoDev 20-Nov-12 7:49am    
Permission denied usually means what it says.
veenusethi 20-Nov-12 23:20pm    
I cant understand why this problem occur

1 solution

I got the solution

I solved myself

this is a permission problem in sql server studio management
step1)Go to sql server management studio and expand security

Step2)Right Click on Login and choose New Login

Step3)Now write in Login name textbox NT AUTHORITY\IUSR

Step4)In left hand of window click on Server roles and now select public

and sysadmin now click on Ok.

Done
if you have already NT AUTHORITY\IUSR user then just check server roles here sysadmin is select or not

Happy Programming

Please Vote if it solved your problem
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900