August 4, 2016

Cannot connect to SQL Server Express from other computer.

Lately, I have a task to install an SQL server on Windows 10 and Nine clients are mix with windows 7 and 10. I used SQL  Server express 2014 as my back-end database and c#, Ms Access through ODBC as my front-end. And now my Database is running smoothly, but before this I countered a problem connecting to database server from other computer on my network. I'm sharing this so if anyone encounter the same can look into this.
  1. Make sure SQL server is running - To check if it is running on Run type services.msc then find SQL Server see if it is running and set to automatically. Else click start or restart.
  2. Make sure both database server and clients are on the same network domain or work group. To change the work group or domain. Right click This PC(my computer) click properties then on computer name tab you can change the workgroup or join the domain.
  3. Firewall Settings - Check the windows firewall settings of the computer where the SQL server express is installed, usually SQL Server port is 1433 make sure it is allowed by your firewall. Disable the windows firewall and try to connect again.
  4. Enable remote connections in your SQL Server Instance - SQL Server Express is set to allow only local connections as default. You need to allow remote connections for the other computer in your network to access your database. 
    1. Enable TCIP Connection - Go to the Computer where SQL server is installed then on Start > Programs > Microsoft SQL server > SQL Server Configuration Manager.  On SQL Network configuration > Protocol for SQLEXPRESS(your instance name) then enable TCP/IP.
    2. Allow network connection on the SQL server instance - Open SQL Management studio then log-in using your authentication, right click on your server name then click Properties, click on connections check on allow network connections to this server, Finally set 600 on remote query time out.

Hope it helps.

No comments:

Post a Comment