HomeHome Product Discus... Product Discus...SmithCartSmithCartSQL Express 2008 ErrorSQL Express 2008 Error
Previous
 
Next
New Post
3/4/2010 12:44 PM
 

I'm getting this error message:

An attempt to attach an auto-named database for file C:\Production\Web\nlcc\nlcc.org\wwwroot\App_Data\Database.mdf failed. A database with the same name exists, or specified file cannot be opened, or it is located on UNC share. To see the error in action - http://nlcc.org.fastarmadillo.com/Default.aspx?tabid=90

Apparently IIS7 and SQL2008 handle user impersonation and access rights much differently from a programmatic standpoint than before. Can you provide us some insight here so I can configure the appropriate rights to get this to work?

Thanks

WB

 
New Post
3/4/2010 3:04 PM
 

Make sure your connection string in your web.config is in this format

<add key="SiteSqlServer" value="Data Source=localhost; Database=XXXXX; uid=YYYYYY; Pwd=ZZZZZZZ;" />


At your service,
Dave Smith
DotNetNuke Consulting, DotNetNuke Store and DNN Ecommerce
 
New Post
3/4/2010 3:20 PM
 

I wish it were that easy. I'm a real old hand at DNN (since at least 2003 - DNN version 1 days). It's not a connection string problem.

The methods I believe you're calling in your code are being deprecated by .NET and SQL. The permissions structure has some pretty significant shifts and I have to grant specific permissions to the IIS worker processes to have the required access to the folder structure to add in any temporary databases you're creating. This used to be easy in server 03/IIS 6, but it's changing.

 
New Post
3/4/2010 3:49 PM
 

I am running VS2008, iis7 and SQL Server 2008 Express on my dev laptop without issue so i dont think the problem is deprecated methods. A couple of the stored procedures do create temp tables which are fully supported in 2008.

I looked at your site and it looks like you dont have the main buynow module on your page just the featured products module. Is the featured products module what is causing the permissions error. Can you post the error from the dnn event viewer.


At your service,
Dave Smith
DotNetNuke Consulting, DotNetNuke Store and DNN Ecommerce
 
New Post
3/5/2010 8:10 AM
 

I've found the resolution to this and it has nothing to do with you guys or your module.

The database was moved via backup and restore from another server. Seems SQL2008 is very sensitive to orphaned user accounts in the database and responds by restricting access to exec in the db even though everything else looks perfect.

Sorry to take up your time. Looking forward to deploying this today.

 
Previous
 
Next
HomeHome Product Discus... Product Discus...SmithCartSmithCartSQL Express 2008 ErrorSQL Express 2008 Error