Sql-server – Can not connect Database to

sql serverssms

I'm trying to connect my server to MS SQL Server Studio but keep on getting an error. On this post I saw that I can use PowerShell to get more information on what the SQL Server is doing. It seems mine is not running and I'm guessing that is why I get the error. How do I turn on my SQL server?

PS C:\Users\rohrl> get-service *sql*

Status   Name               DisplayName
------   ----               -----------
Stopped  MSSQL$SQLEXPRESS   SQL Server (SQLEXPRESS)
Stopped  SQLAgent$SQLEXP... SQL Server Agent (SQLEXPRESS)
Stopped  SQLBrowser         SQL Server Browser
Stopped  SQLTELEMETRY$SQ... SQL Server CEIP service (SQLEXPRESS)
Running  SQLWriter          SQL Server VSS Writer

Best Answer

you have to start the services by control panel/services or by command:

net start MSSQL$SQLEXPRESS
net start "SQL Server Browser"

please, take a look at this:

https://docs.microsoft.com/en-us/sql/database-engine/configure-windows/start-stop-pause-resume-restart-sql-server-services?view=sql-server-ver15