Unable to login to sql server - sql-server

I dont know much about sql server.
I have just re-installed windows 7 on my laptop. After that I installed Visual Studio 2012 Express Edition. I also Installed SQL Server Management Studio 2008 R2.
Now when I try to log in to sql server management studio by using server name as . or (local) or .\SQLEXPRESS or PC-Name\SQLEXPRESS and using Windows Authentication I get the error as below.
Please dont mark this question as negative as I have searched on google for last 4 hours but did not understand the problem.
Update:

There are many reasons that may cautioning the problem:
SQL Server is not running
SQL Server is not properly configured
You try to connect with a worng instance Name
You can try the following:
Go to Mycomputer->Rigt Click->Manage->Application and Services
And from there check that SQL Server Express is running
2.From there also, gCheck the Instance name of your SQL Express and be sure when you log on to Management Studio you Provide the same Instance name

Confirm that the service is installed and running. Under Computer Management, drill-down into Services and Applications -> Services.
There should be a service named "SQL Server (SQLEXPRESS)". Try a restart or start of the service.
If any other instance of SQL Server is installed it will be listed - try connecting to LOCALHOST(whatever the instance is listed as) to verify the installation is functional.
UPDATED following further information from comments:
You may have only installed the client tools (management studio), and have not installed the database service. Ensure you have the correct installer which includes the database services engine.

First check that the SQL Server parameters are set accordingly.
Go to Start -
All Programs — Microsoft SQL Server 2008 R2 — Configuration tools —
SQL Server Configuration Manager
Under SQL Server Services, make sure that the instance is running :
SQL Server ()
SQL Server Browser
Under SQL Server Network Configuration - Protocols for (), these are enabled:
TCP/IP
Named Pipes
Do the same under SQL Native Client 10.0 under Client Protocols

Related

SQL Server Management Studio And Network Server Discovery

I just installed SQL Server Management Studio, version 18.9.1, on a Windows 10 system. The installed Management Studio cannot discover known SQL Server databases out on the network, so I cannot log into a SQL Server using SQL authentication.
Please note, the target SQL Server has been installed for a while, and is running fine. I am trying to access this SQL Server from a new workstation.
The SQL Server Browser is running on the SQL Server I am trying to reach.
I am confused as to what should be installed if what I installed is not correct. I'm also confused as to which services to check are installed after installation. It doesn't look like a SQL Agent or locator service was installed, after I installed SQL Server Management Studio.
Am I better off installing a development database and just not using it in order to get the locator service?

SQL Server Databases missing after installing SQL Server Express

I installed SQL Server 2017 Express as a named Instance alongside my default instance. After rebooting once - both were showing but the I could not connect to SQL Server Express remotely. I then followed the instructions to enable IP on SQL Express using configuration manager and rebooted. Now I can connect remotely but my default instance is showing NO databases!
Also in configuration manager, SQL Server Services does not show any of my instances so that I can check they are running (this was the care even prior to enabling the IP address on the protocol, and when I knew it definitely was running as I could connect to it)
--
Update:
I discovered if I launch SQL Server Configuration Manager 2016 rather than "SQL Server Configuration Manager" I can see all my servers.
SQL Server 2016 appears to be running as is SQL Server Express. There is also a "MSSQLServer" that is stopped - think this may be SQL Server 2012. Not sure at this stage which one had the databases.
Ok so for anyone in a similar situation / panic. Do the following.
Look to see what other SQL Server configuration mangers are showing up. If you have installed multiple versions over the years chances are you'll see more than one.
Try using one of the later ones. You can see the file path too if you need it here.
If you manage to see a list of your database servers, check which are enabled and disabled. I had to disable SQL Server (SQLExpress) first before I could enable SQL Server (MSSQLServer), which in my case referred to SQL Server 2012.
If you want to have SQL Server Express running as a named server running alongside your default server, make sure you assign it a different port number (e.g. 1435) in the SQL Server Network Configuration>Protocols for SQL Express>TCP/IPALL section in SQL Server configuration manager.

Microsoft SQL Server Management Studio unable to connect to Server

I freshly installed Microsoft SQL Server on my machine and started it. When I try to connect to a server I use a . for the server name (which should point to the local machine from what I read?). However I get the following error:
So I went to the SQL Server Configuration Manager and checked under SQL Server Services, which seems to be empty.
How can I establish a connection?
Your services are not running.
Make sure you installed this.
The above answer was correct, however, you only installed the SQL Server Management Studio.
If you installed Express, downloaded from the Microsoft website you might want to download and create the server instance with the management studio. You will need to select if you want Windows authentication or SQL Server authentication using a username and password. Remember to add the current windows user for using either.
Here is SQL Server 2014 Express: http://msdn.microsoft.com/en-us/evalcenter/dn434042.aspx.
This will download everything you need to connect to a server.
Please let me know if you need more information.

SQLExpress instance seems to be absent

I am trying to connect to a SQL Server Express instance on my laptop; I have SQL Server 2008 installed in my system, but when I try to put the instance (local)/SQLEXPRESS or Jashobanta-PC/SQLEXPRESS in my system, I am not able to connect to it. It is appearing that it is not even present in my system.
I am getting the following error :-
A network-related or instance-specific error has occurred while establishing a connection to SQL Server. Server is not found or not accessible. Check if instance name is correct and if SQL Server is configured to allow remote connections. For more information see SQL Server Books Online..
I have tried using the SQLCMD command tool also for this, but the result is same:-
sqlcmd -E -S .\SQLEXPRESS
Here also the same error is appearing.
Is there any chance that SQLEXPRESS is not installed in my system? But as MVC Code First uses SQL Server Express, I need it. When I use code first, then the files are created fine, but how it is connecting, where it is creating the database, it is not known.
Any suggestions will be helpful.
Thanks in advance
Jashobanta
I had a similar issue to this, so for google purposes I'll list my result.
My take on the problem was that I had a SQL2008 Express instance, that had 'gone dark' because I'd installed a full instance of SQL2008R2 and/or SQL Express 2012. My guess is that one or the other of these turns off the out-of-date express instance as a security risk.
These instances were installed as fresh instance names, but somewhere along the way my (local)\SQLEXPRESS instance was disabled.
Using this link I used the SQL2008R2 installer to upgrade the SQLEXPRESS instance that the installer detected.
Once the SQLEXPRESS instance was upgraded to 2008R2 it was happily re-enabled and accessible at (local)\SQLEXPRESS, with all my previous databases inside it.
I have a same problem just now. What you need to do to resolve the problem is to install SQL Server 2008 Express edition.
You can do this by searching "SQL Express" from Web Platform Installer and install "SQL Server 2008 Express with Advanced Series" and "SQL Server 2008 Express with Tools".
Or
Download from this url and install.
http://www.microsoft.com/en-us/download/details.aspx?id=1695
.\SQLEXPRESS is SQL Express for SQL Server 2008 while
(LocalDB)\v11.0 is SQL Express for SQL Server 2012 / 14

No services listed when SQL Server Express 2008 R2 Installed on local computer

I cannot get my local computer to run SQL Server. I looked in the SQL Server configuration manager and noticed that there are no SQL Server Services listed. That can't be right. I also noticed that There are two Managers listed in the SysWOW64 folder (I'm running Win7): SQLServerManager10.msc and SQLServerManager.msc. Neither show any services at all. When trying to connect via SSMSE, I get the standard:
A network related or instance specific error occurred while establishing a
connection to SQL server...
I haven't installed a prior version, but did try to uninstall and reinstall using the Web platform installer from Microsoft. Any suggestions?
Thanks
I had the same problem and as Brian said, I was missing SQL Server Express. So I download SQL Server 2008 R2 Express and I installed it. now everything works fine.
Note that I thought I already installed it when I installed SQL Management Studio R2. Now, be aware that when installing SQL Management Studio R2, you are not installing SQL Server and you won't get any SQL Server Services in your Sql Server Configuration Manager -> SQL Server Services. You also need to download and install SQL Server Express.
Is SQL Server listed in services? (Start->Run->Services.msc)
If so, is it running?
That is an instance error, meaning you cannot connect to the instance. Most likely there is no instance installed on this machine. Meaning your not connecting correctly to the instance. Connect to the database engine again and check the server name and make sure your connecting to the correct server name or the local host, depending if this is a local machine or if this is on a server. Go back through setup and see if there are any features that didn't get installed. Try that and see if it works. If not then reinstall SQL Server and make sure all folders are removed and nothing is left behind before you reinstall.

Resources