Products

Solutions

Resources

Partners

Community

Blog

About

QA

Ideas Test

New Community Website

Ordinarily, you'd be at the right spot, but we've recently launched a brand new community website... For the community, by the community.

Yay... Take Me to the Community!

Welcome to the DNN Community Forums, your preferred source of online community support for all things related to DNN.
In order to participate you must be a registered DNNizen

HomeHomeGetting StartedGetting StartedInstalling DNN ...Installing DNN ...Could not connect to database!!!Could not connect to database!!!
Previous
 
Next
New Post
9/19/2006 12:42 PM
 

Hi

I think you forgot to remove the comments from the one you want to use and you should comment out or as suggested delete the ones not being used.
it only creates more confusion.
Also from security point of view, agreed .config files are not served by iis "yet" but why find out the hard way ?

<connectionStrings>
    <!-- Connection String for SQL Server 2005 Express -->

<!-- comment out this part
    <add
      name="SiteSqlServer"
      connectionString="Data Source=.\SQLExpress;Integrated Security=True;User Instance=True;AttachDBFilename=|DataDirectory|Database.mdf;"
      providerName="System.Data.SqlClient" />   
-->

<!-- Connection String for SQL Server 2000/2005 --> <- should have been here
    <add
      name="SiteSqlServer"
      connectionString="Server=user-f5556bf10d;Database=DotNetNuke;uid=hassan;pwd=Buster;"
      providerName="System.Data.SqlClient" />
   --> <-- this is the error 
  </connectionStrings>

Another friendly suggestion,

Its not a good idea to cut / paste your connection strings into any forums, you are giving away your username / pwd, if it makes it into production by mistake...


Regards KM
 
New Post
9/19/2006 1:04 PM
 

It must be.  It is sconfusing me big time as I can see your replies but not mine.  When i do a post, it says "since you posted to a moderated list, it may take your post to be authorised somewhere between few minutes to several hours"  I wish this wan't the case.  I also set noify me when this post gets a reply but I am not getting any emails either.  c'mon DDN guys make this thing a little easier for us newbies !!!

HEELLPPP!!!

 

 
New Post
9/19/2006 1:11 PM
 
Your connection string is commented out.

<START: REMOVE THIS ONE>

<!-- Connection String for SQL Server 2005 Express -->
<add name="SiteSqlServer"
     connectionString="Data Source=.\SQLExpress;Integrated Security=True;User  Instance=True;AttachDBFilename=|DataDirectory|Database.mdf;"
     providerName="System.Data.SqlClient" />

<END: REMOVE THIS ONE>

Change this one:

<!-- Connection String for SQL Server 2000/2005
    <add
      name="SiteSqlServer"
      connectionString="Server=user-f5556bf10d;Database=DotNetNuke;uid=hassan;pwd=Buster;"
      providerName="System.Data.SqlClient" />
   -->

 to:


<!-- Connection String for SQL Server 2000/2005 -->
    <add
      name="SiteSqlServer"
      connectionString="Server=user-f5556bf10d;Database=DotNetNuke;uid=hassan;pwd=Buster;"
      providerName="System.Data.SqlClient" />
  


Make sure you check the other connection string entry for legacy support and change accordingly.
 
New Post
9/19/2006 3:06 PM
 

Thanks Ed,

I have already fixed (maybe!) the connection string the way you said it.  I am still having the same problem as shown far below. 

One thing I am not sure is:
What connectionstring should I use?.  The one you suggested seems to be my server/userid/pwd at DNN site.  I am hosting my site elsewhere and I used the connectionstring they provided.  The database that was auto-created for me, however, is not called DotNetNuke.  is this a requirement for DotNetNuke to work - that databse is called DotNetNuke?
More importantly, why can't I see the actual error rather than the one obscure one I posted above.  seeing the error would point me to the right direction.  My CustomErrors tag is currently set as

<customErrors mode="Off"/>


Many thanks for your support

====================================================

Runtime Error

Description: An application error occurred on the server. The current custom error settings for this application prevent the details of the application error from being viewed remotely (for security reasons). It could, however, be viewed by browsers running on the local server machine.

Details: To enable the details of this specific error message to be viewable on remote machines, please create a <customErrors> tag within a "web.config" configuration file located in the root directory of the current web application. This <customErrors> tag should then have its "mode" attribute set to "Off".

<!-- Web.Config Configuration File -->

<configuration>
    <system.web>
        <customErrors mode="Off"/>
    </system.web>
</configuration>

Notes: The current error page you are seeing can be replaced by a custom error page by modifying the "defaultRedirect" attribute of the application's <customErrors> configuration tag to point to a custom error page URL.

<!-- Web.Config Configuration File -->

<configuration>
    <system.web>
        <customErrors mode="RemoteOnly" defaultRedirect="mycustompage.htm"/>
    </system.web>
</configuration>

 

 
New Post
9/29/2006 3:54 PM
 
Hakkoos wrote

Hi,

we are trying to install latest version and we have got to the point where Database is fine we tested with VS 2005 and connection works fine.  When we try to run the install page we get error "

Error Installing DotNetNuke

Current Assembly Version: 04.03.05

ERROR: Could not connect to database specified in connectionString for SqlDataProvider

"

In uor web.config we setup our connection string as

 
   
          name="SiteSqlServer"
      connectionString="Data Source=.\SQLExpress;Integrated Security=True;User Instance=True;AttachDBFilename=|DataDirectory|Database.mdf;"
      providerName="System.Data.SqlClient" />
 

 

We are using SQL Server 2005  (not express 2005)

Can someone please tell us what we are doing wrong.

Many thanks 

I have same problem but my connection strings are marked ok.

As it tested in Server Explorer in Visual studio.

I already lost about 5½ hours in finding solution.

I better stick with 3.2 version. :-)

 
Previous
 
Next
HomeHomeGetting StartedGetting StartedInstalling DNN ...Installing DNN ...Could not connect to database!!!Could not connect to database!!!


These Forums are dedicated to discussion of DNN Platform and Evoq Solutions.

For the benefit of the community and to protect the integrity of the ecosystem, please observe the following posting guidelines:

  1. No Advertising. This includes promotion of commercial and non-commercial products or services which are not directly related to DNN.
  2. No vendor trolling / poaching. If someone posts about a vendor issue, allow the vendor or other customers to respond. Any post that looks like trolling / poaching will be removed.
  3. Discussion or promotion of DNN Platform product releases under a different brand name are strictly prohibited.
  4. No Flaming or Trolling.
  5. No Profanity, Racism, or Prejudice.
  6. Site Moderators have the final word on approving / removing a thread or post or comment.
  7. English language posting only, please.
What is Liquid Content?
Find Out
What is Liquid Content?
Find Out
What is Liquid Content?
Find Out