Need some help

Discussion in 'Databases' started by pk0321, Apr 22, 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 have started a new website. This is my first time uploading a website to the internet, I have always just played around locally.

    I have added a LOGIN control to my site and it works fine locally, but does not connect to the database on the site.

    How do I get my site to point to the database. I added a SQL 2005 database to my site, but do not know how to configure.

    Please help?
     
  2. Thank you, I appreciate the links, but I am still having no luck. I think I have bitten off more than I can handle. I can not believe that it is this difficult. All the articles are not helping. I follow the instructions best I can but still no luck.


    I have added a SQL 2005 database to my site. I am using Visual Web Developer 2005. My site is running on a Windows 2003 server running IIS6 I believe which I also configured on my local machine.


    I need someone to walk me through step by step how to make my local copy of my site connect to the database I added to my website once I upload it to the server. Arghhh!
     
  3. Have you watched these Videos?
    http://asp.net/learn/

    Most of them were made using VWD.

    If you need a specific step-by-step you don't see there let me know and I'll create a video.
    Salute,
    Mark
     
  4. Is there a particular video that you recommend. I have watched most of these and they are too broad.
     
  5. I think I am making some progress. I have been able to connect to my SQL Database on DISCOUNTASP.NET. I have also ATTACHED my ASPNETDB.MDF to the database named SQL2005_468377_gmi1 and then verified the tables are in the database.

    But I still get the following error when I try to login to my site:

    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 Interfaces, error: 26 - Error Locating Server/Instance Specified)


    My connection stringis as follows (password replaced with ******):


    <connectionStrings>
    <add name="LocalSqlServer
    connectionString="Data Source=tcp:sql2k507.discountasp.net;Initial Catalog=SQL2005_468377_gmi1;
    User ID=SQL2005_468377_gmi1_user;Password=******; Integrated Security=SSPI;User Instance=true"
    providerName="System.Data.SqlClient"/>
    </connectionStrings>


    Are the login controls looking for a database names ASPNETDB.MDF or a datasource name? I know this will all make sense once it all comes together?


    What should my next step be? Thanks in advance, Tony
     
  6. At times using the Clear and Add Remove commands will resolve this.
    Try your connection string like this and see if it helps:

     
  7. Thanks for the help. I finally go it working. I ended up having toremoveproviderName="System.Data.SqlClient fromt he connection string. I guess this point to a mySQL database and I was using a SQL 2005 database.


    Another question for ya though. Now that my ASPNETDB.MDF file is attached to my SQL database on DISCOUNTASP.NET, what is the purpose of the ASPNETDB.MDF file in my application? Do I stil need it?
     
  8. No you don't need it anymore, just back it up on your local system somewhere in case you need it again.
     
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