| | |
issue on production database connection
Please support our ASP.NET advertiser: Intel Parallel Studio Home
Thread Solved |
•
•
Join Date: Jan 2009
Posts: 13
Reputation:
Solved Threads: 0
Hi,
I have hosted a website that has MSSQL Server 2005 database on different machine. I am using the following connection string
I am getting the following error.
A network-related or instance-specific error occurred while establishing a connection to SQL Server. The server was not found or was not accessible. Verify that the instance name is correct and that SQL Server is configured to allow remote connections. (provider: SQL Network Interfaces, error: 26 - Error Locating Server/Instance Specified)
What may be the potential problem. ?
I am able to connect to the same database using same user id and password through third party software that allows me to monitor it. why my website is not able to connect to it ?
Any suggestion appreciated.
I have hosted a website that has MSSQL Server 2005 database on different machine. I am using the following connection string
ASP.NET Syntax (Toggle Plain Text)
<add name="ConnectionString" connectionString="Server=mssql2005.ableos.com.au;Database=visualinventory_ableos_com_au;Uid=myuserid;Pwd=mypassword;Integrated Security=True;User Instance=True" providerName="System.Data.SqlClient" />
I am getting the following error.
A network-related or instance-specific error occurred while establishing a connection to SQL Server. The server was not found or was not accessible. Verify that the instance name is correct and that SQL Server is configured to allow remote connections. (provider: SQL Network Interfaces, error: 26 - Error Locating Server/Instance Specified)
What may be the potential problem. ?
I am able to connect to the same database using same user id and password through third party software that allows me to monitor it. why my website is not able to connect to it ?
Any suggestion appreciated.
Last edited by peter_budo; Jun 12th, 2009 at 12:20 pm. Reason: Keep It Organized - For easy readability, always wrap programming code within posts in [code] (code blocks) and [icode] (inline code) tags.
My Blog: http://technobird.blogspot.com/
•
•
Join Date: Jun 2009
Posts: 124
Reputation:
Solved Threads: 11
This should resolve the problem.
Visual Studio => Tools => Options => Database Tools => Design Time - Validation Database => Connection options
Set the sql server instance name to Blank. Please check if this works.
Visual Studio => Tools => Options => Database Tools => Design Time - Validation Database => Connection options
Set the sql server instance name to Blank. Please check if this works.
Your connection string has a problem.. If you are using Integrated Security=True then you should not specify a user name and password.
Also I think "uid=" is only valid for an MSSQL connection string if you are using the ODBC driver. I don't think it is valid for Native SQL Client?
Set the connection string as:
or
Also I think "uid=" is only valid for an MSSQL connection string if you are using the ODBC driver. I don't think it is valid for Native SQL Client?
Set the connection string as:
ASP.NET Syntax (Toggle Plain Text)
<add name="ConnStr" connectionString="Data Source=apex2006sql;Initial Catalog=Bugs;Integrated Security=False;User Id=?username?;Password=?password?;" providerName="System.Data.SqlClient" />
ASP.NET Syntax (Toggle Plain Text)
<add name="ConnStr" connectionString="Data Source=apex2006sql;Initial Catalog=Bugs;Integrated Security=True;" providerName="System.Data.SqlClient" />
Yes i think the above poster is right. Also check that Sql server configuraton allows remote connection. To do that follow the steps below:
Click Start -->> Programs -->> Microsoft SQL Server 2005 -->>
Configuration Tools -->> SQL Server Surface Area Configuration.
Now click Surface Area Configuration for Services and Connections.
Now expand Database Engine, click Remote Connections, click Local and remote connections, click the appropriate protocol to enable for your environment, and then click Apply.
Restart MSSQLSERVER service from
Start -->> Control Panel -->> Administrative Tools -->>
Service -->> Select MSSQL Server -->> Restart Service
Click Start -->> Programs -->> Microsoft SQL Server 2005 -->>
Configuration Tools -->> SQL Server Surface Area Configuration.
Now click Surface Area Configuration for Services and Connections.
Now expand Database Engine, click Remote Connections, click Local and remote connections, click the appropriate protocol to enable for your environment, and then click Apply.
Restart MSSQLSERVER service from
Start -->> Control Panel -->> Administrative Tools -->>
Service -->> Select MSSQL Server -->> Restart Service
MARK AS SOLVED if its help you.
REGARDS
MCTS - Shawpnendu bikash maloroy
http://shawpnendu.blogspot.com
REGARDS
MCTS - Shawpnendu bikash maloroy
http://shawpnendu.blogspot.com
•
•
Join Date: Jan 2009
Posts: 13
Reputation:
Solved Threads: 0
Thankx for your suggestion.
It resolve the issue with both IIS and SQL Server 2005 on same machine.
It resolve the issue with both IIS and SQL Server 2005 on same machine.
My Blog: http://technobird.blogspot.com/
Great, I'm glad to see you got it working!
Please mark this thread as solved if we have answered your question.
Please mark this thread as solved if we have answered your question.
![]() |
Similar Threads
- DataBase connection in Jsp to MS-Access (JSP)
- external database connection (MySQL)
- database connection(select ,insert query) within javascript function (JSP)
- database connection (PHP)
- Problem with database connection (JSP)
- Visual C++, Database connection, please help (C++)
Other Threads in the ASP.NET Forum
- Previous Thread: unable to start the virtual machine
- Next Thread: Login page button(visual basic)
| Thread Tools | Search this Thread |
.net 2.0 activexcontrol advice ajax alltypeofvideos asp asp.net bc30451 bottomasp.net browser businesslogiclayer button c# c#gridviewcolumn checkbox click commonfunctions compatible confirmationcodegeneration content contenttype courier css dataaccesslayer database datagridview datagridviewcheckbox datalist deadlock development dgv dropdownlist dropdownmenu dynamically edit expose fill flash flv formatdecimal forms formview gridview homeedition iframe iis javascript jquery listbox login menu microsoft mono mouse mssql multistepregistration news numerical objects opera order panelmasterpagebuttoncontrols radio ratings registration reportemail rotatepage save schoolproject search security serializesmo.table silverlight smartcard smoobjects software sql-server sqlserver2005 suse textbox tracking unauthorized validation vb.net video videos virtualdirectory vista visual-studio visualstudio web webapplications webarchitecture webdevelopemnt webprogramming webservice xml xsl youareanotmemberofthedebuggerusers






