473,322 Members | 1,510 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,322 software developers and data experts.

An attempt to attach an auto-named database for file c:\inetpub\wwwroot\WebSite\App_Data\aspnetdb.mdffa iled

hi,

i try to get the asp.net 2.0 security controls to work with SQL Server
2005 Dev RTM, this is my connetion string in mashine.config

<connectionStrings>
<add name="LocalSqlServer" connectionString="data
source=.;Integrated
Security=SSPI;AttachDBFilename=|DataDirectory|aspn etdb.mdf;User
Instance=false;" providerName="System.Data.SqlClient" />
</connectionStrings>

the aspnet account has sql login w/ administrative rights, this is the
error msg:
[SqlException (0x80131904): An attempt to attach an auto-named database
for file c:\inetpub\wwwroot\WebSite\App_Data\aspnetdb.mdf failed. A
database with the same name exists, or specified file cannot be opened,
or it is located on UNC share.]

the c:\inetpub\wwwroot\WebSite\App_Data\ folder is local, this is new
install of the sql server, there r no databases created after install,
App_Data folder exists and aspnet has full control over it
Jul 21 '06 #1
3 8600
Why atatch the MDF file in the connection string. I would atatch the DB
using the SQL Server Management Studio and then just connect to it using the
connection string.

"Freddie" wrote:
hi,

i try to get the asp.net 2.0 security controls to work with SQL Server
2005 Dev RTM, this is my connetion string in mashine.config

<connectionStrings>
<add name="LocalSqlServer" connectionString="data
source=.;Integrated
Security=SSPI;AttachDBFilename=|DataDirectory|aspn etdb.mdf;User
Instance=false;" providerName="System.Data.SqlClient" />
</connectionStrings>

the aspnet account has sql login w/ administrative rights, this is the
error msg:
[SqlException (0x80131904): An attempt to attach an auto-named database
for file c:\inetpub\wwwroot\WebSite\App_Data\aspnetdb.mdf failed. A
database with the same name exists, or specified file cannot be opened,
or it is located on UNC share.]

the c:\inetpub\wwwroot\WebSite\App_Data\ folder is local, this is new
install of the sql server, there r no databases created after install,
App_Data folder exists and aspnet has full control over it
Jul 21 '06 #2
becouse it`s harder to deploy
Why atatch the MDF file in the connection string. I would atatch the DB
using the SQL Server Management Studio and then just connect to it using the
connection string.

"Freddie" wrote:

>>hi,

i try to get the asp.net 2.0 security controls to work with SQL Server
2005 Dev RTM, this is my connetion string in mashine.config

<connectionStrings>
<add name="LocalSqlServer" connectionString="data
source=.;Integrated
Security=SSPI;AttachDBFilename=|DataDirectory|as pnetdb.mdf;User
Instance=false;" providerName="System.Data.SqlClient" />
</connectionStrings>

the aspnet account has sql login w/ administrative rights, this is the
error msg:
[SqlException (0x80131904): An attempt to attach an auto-named database
for file c:\inetpub\wwwroot\WebSite\App_Data\aspnetdb.mdf failed. A
database with the same name exists, or specified file cannot be opened,
or it is located on UNC share.]

the c:\inetpub\wwwroot\WebSite\App_Data\ folder is local, this is new
install of the sql server, there r no databases created after install,
App_Data folder exists and aspnet has full control over it
Jul 21 '06 #3
There are umpteen people who have wasted countless hours over the
message "an attempt to attach an auto-named database........" One reply
has at least a half a dozen fixes, none of which work. Where, pray
tell, is the SQL Server Management Studio. I use Visual Web Management
2005 Express. What do I click to get to the SQL Management Studio. It's
the only approach I haven't tried. Maybe VWM 2005 Express doesn't have
SQL Mgmt Studio.
Many thanks for your help
clickon wrote:
Why atatch the MDF file in the connection string. I would atatch the DB
using the SQL Server Management Studio and then just connect to it using the
connection string.

"Freddie" wrote:
hi,

i try to get the asp.net 2.0 security controls to work with SQL Server
2005 Dev RTM, this is my connetion string in mashine.config

<connectionStrings>
<add name="LocalSqlServer" connectionString="data
source=.;Integrated
Security=SSPI;AttachDBFilename=|DataDirectory|aspn etdb.mdf;User
Instance=false;" providerName="System.Data.SqlClient" />
</connectionStrings>

the aspnet account has sql login w/ administrative rights, this is the
error msg:
[SqlException (0x80131904): An attempt to attach an auto-named database
for file c:\inetpub\wwwroot\WebSite\App_Data\aspnetdb.mdf failed. A
database with the same name exists, or specified file cannot be opened,
or it is located on UNC share.]

the c:\inetpub\wwwroot\WebSite\App_Data\ folder is local, this is new
install of the sql server, there r no databases created after install,
App_Data folder exists and aspnet has full control over it
Jul 26 '06 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
by: Tiraman | last post by:
Hi , I have a Stored Procedure that return an xml (by using the xml auto or explicit) in to some XmlReader and i m getting the following error . Invalid attempt to GetBytes on column ''....
3
by: John Ortt | last post by:
> I have a table of dates in ascending order but with varying intervals. I > would like to create a query to pull out the date (in field 1) and then pull > the date from the subsequent record...
0
by: Nick | last post by:
Hi, I would like to know how to attach a RichTextBox which auto scale with Windows Form? Thanks Nick
4
by: Andy | last post by:
In visual studio, I have an asp.net project. When I debug, I have to manually attach to aspnet_wp.exe. My project used to automatically attach to this process. How do I get it to automatically...
0
by: Reshma Prabhu | last post by:
Hello, I am getting following meesage when trying to debug an SP.Net application Auto-attach to process ' aspnet_wp.exe' on machine <Machnine Name> failed. Error code 0x8013134b. Unable to...
1
by: Reshma Prabhu | last post by:
I am getting follwoing error while trying to debug through IDE Auto-attach to process ' aspnet_wp.exe' on machine machinename failed. Error code 0x8013134b. Can any tell me please how to solve...
4
by: John A. Bailo | last post by:
I am debugging a windows service that consumes a web service. I set breakpoints in both. Sometimes, after attaching to the windows service, the debugger will auto-attach and run to my...
11
by: Greg P | last post by:
I'm using VB 2005, and have drug and dropped datagridviews onto my form. The default code that is generated for inserts tries to insert a value for the auto generated primary key. Below is the...
4
by: Dessip | last post by:
Hey, I know this has probbly been asked 100's of times, but i have yet to manage to find anyone asking what i am about to ask in this mannor. Basically here is the code: strFunction =...
2
by: windandwaves | last post by:
Hi Folk I want to add an "onClick" function to the radio boxes, but I am having trouble. Can you help me <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
1
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
1
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.