Unable to connect Database server

Posted by karunakar5788-15015 under ASP.NET on 5/2/2012 | Points: 10 | Views : 2300 | Status : [Member] | Replies : 2
hi,
am developing Knowledge Sharing kind of WebSite.Right now am looking into Profle and membership concepts

in solution we have Asp.net(Configuration) is there..am using that configuration.

from the asp.net configuration am select Web Site Administration Tool


this is not working not properly. so am getting these kind Of Issues .please Resolve these.

--------------------------------------------------------------------------------------------------------------------------------------------------
There is a problem with your selected data store. This can be caused by an invalid server name or credentials, or by insufficient permission. It can also be caused by the role manager feature not being enabled. Click the button below to be redirected to a page where you can choose a new data store.

The following message may help in diagnosing the problem: Unable to connect to SQL Server database.

----------------------------------------------------------------------------------------------------------------------------------------------------

------------------------------------------------------------------------------------------------------------------------------------------------------
Could not establish a connection to the database.
If you have not yet created the SQL Server database, exit the Web Site Administration tool, use the aspnet_regsql command-line utility to create and configure the database, and then return to this tool to set the provider.
------------------------------------------------------------------------------------------------------------------------------------------------------




Regards,
Karunakar

Karunakar


Responses

Posted by: karunakar5788-15015 on: 5/29/2012 [Member] Starter | Points: 25

Up
0
Down
Verify if the sql services are OK, execute -> Services.msc -> if the service: SQL SERVER is not started, do it and try to connect again.

happy Programming!!!

Karunakar

karunakar5788-15015, if this helps please login to Mark As Answer. | Alert Moderator

Posted by: perfectchourasia-9163 on: 6/8/2012 [Member] Starter | Points: 25

Up
0
Down
using System.data.sqlclient;
Use Dal Class for better performance....


if (!IsPostBack)
{
DataSet dt = DAL.ExecuteDataset("Server=.;uid=sa;pwd=sa123;database=Enigma", CommandType.Text, "select * from dbo.UserDetail");
if (dt != null)
{
DataView dv = dt.Tables[0].DefaultView;
dv.RowFilter = "Address1 like '%Japan%' and Address2='Developing'";
dv.Sort = "Address2 desc";
lbldata.DataSource = dv;
lbldata.DataBind();

}
}

ER sandeep chourasia
sandeepchrs@yahoo.com (on facebook)
http://www.aspnetcodes.com/

karunakar5788-15015, if this helps please login to Mark As Answer. | Alert Moderator

Login to post response