Problems Logging In After DB Restore

Discussion in 'Databases' started by pinch, Sep 12, 2008.

Thread Status:
Threads that have been inactive for 5 years or longer are closed to further replies. Please start a new thread.
  1. I am having a problem relating to restoring a database on the server and authenticating using that DB. I needed to make a couple of changes to the schema of the database on the server, then upload it back to the server, and ran into a problem. Here are the steps I took:

    1. I generated a .bak of my server DB using the SQL Backup Tool.

    2. I generated a database based on this .bak on my local machine.

    3. I made the necessary changes to the DB locally. (Things were working fine when testing locally).

    4. I uploaded the modified .mdf to the server using FTP.

    5. I changed the necessary connection strings to point to the new DB.

    6. I attached the DB using the Attach tool.

    7. When testing the application, I can connect to the DB and pull data. However, I cannot login to the application even though my login credentials are stored in the same DB that seems to be functional for pulling other data; I have no problems authenticating locally.

    Here is the error that I get when I attempt to login:

    "Server Error in '/' Application"
    "An error has occurred while establishing a connection to the server. When connecting to SQL Server 2005, this failure may be caused by the fact that under the default settings SQL Server does not allow remote connections. (provider: SQL Network Interface, error: 26 - Error Locating Server/Instance specified)

    Points:

    1. I'm positive that the connection string is correct because I can pull other data from the same DB where my login credentials are stored.

    2. Everything works fine locally, its only when I upload the DB to the server that I cannot login.

    Thanks.
     
  2. Bruce

    Bruce DiscountASP.NET Staff

    do you have more than 1 connection string in your application?


    can you post the connection string section (mask out the DB password)?


    Bruce

    DiscountASP.NET
    www.DiscountASP.NET
     
  3. Bruce,

    I repeated my above steps and things began to work properly, though I'm still not sure what the problem was. Thanks.

    Post Edited (pinch) : 9/14/2008 5:53:38 PM GMT
     
Thread Status:
Threads that have been inactive for 5 years or longer are closed to further replies. Please start a new thread.

Share This Page