connection error with sql database in ASP.net RRS feed

  • Question

  • Hi devs, 

    my friend gave me an ASP.net project for a pharmacy system so I can reuse it, the project was running 100% back then, but when I tried to run it on my machine I got the common exception "

    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 "

    I'm not too familiar with sql or asp.net, I have a thought that this exception pops up because I don't SQL server on my machine, is that true? if not can anyone help me here

    thanks and best  

    • Moved by Bob Beauchemin Saturday, August 13, 2016 6:10 PM Moved to the forum for client-side SqlClient for best results
    Saturday, August 13, 2016 8:01 AM


  • More precisely, there is no SQL Server running where the connection string in the project points to. That is, if it points to local instance, you need SQL Server running on your machine - and with the same instance name. If the connection string points to a different machine, it does not help if you have SQL Server running on your machine.

    I think the best that you talk with your friend to set this up.

    • Marked as answer by Bassel Damra Saturday, August 13, 2016 1:43 PM
    Saturday, August 13, 2016 8:15 AM