dynamic connection strings...

Results 1 to 2 of 2

Thread: dynamic connection strings...

  1. #1
    Join Date
    Dec 1969

    Default dynamic connection strings...

    Could someone please point me in the right direction....<BR><BR>I am building a simple content management system, which will be used by multiple websites. Each website will have a database (sql server 2000) set up for there website. So if I have 4 websites, there will be 4 copies of the database.<BR><BR>The code that allows people to edit pages on their website will not be duplicated for each website, Instead I want to create their connection string when they login (stored in a seperate database, eg.. SELECT connectionString FROM tblClients WHERE UserName = suppliedusername AND txtpassword = supplied password), and use this connection string every time they need to connect to the database. This way if I make code changes I don&#039;t have to make a change for every website using the CMS.<BR><BR>In Classic ASP i would store the connection string in a session variable... Do i have any different options in ASP.NET that would be more efficient?<BR><BR>Thank you.

  2. #2

    Default RE: dynamic connection strings...

    If you don&#039;t mind using the session, it&#039;s fine.<BR>The info remains on the server.<BR>You might want to store it in a CMS_Instances table instead of in the clients<BR><BR>ADO.Net is going to use the value of the string, it doesn&#039;t care where it comes from.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts