Connection Issues with SQL Server Express

2

I have windows 7 Ultimate, 64bit. I have installed SQL Server 2008 Express and have created a database in it.

I have a jar that helps me create a connection file to connect to this database. I have used this on several other computers (XP/Win2003) and it has worked fine. alt text

However, testing the connection gives me a connection refused.

So I started troubleshooting by first installing the Telnet client and trying to hit SQL Server Express. No joy: alt text

This is my home PC. No Windows Firewall running. Default install of SQL Server (port number is 1433) Can hit SQL Server in SQL Server Mgmt Studio fine.

  1. Why is Telnet failing?
  2. How to troubleshoot further?

Thanks.

Simon

Posted 2010-10-09T00:13:03.540

Reputation: 675

Answers

4

Have you enabled TCP/IP as a connection option for the instance in SQL Server Configuration Manager?

ta.speot.is

Posted 2010-10-09T00:13:03.540

Reputation: 13 727

Thank you - that solved the 95% of the issue. Im sure default installs of 2005 SQL Server express have this enabled? Its now saying the sa login is not right. I was pretty certain the default password for sa was sa? – Simon – 2010-10-09T01:02:57.147

@Simon - the default password for sa is whatever you set it to in the installation, if you enabled mixed mode authentication. See http://thecodeattic.files.wordpress.com/2010/06/062710_1628_sqlserver2010.png?w=600

– ta.speot.is – 2010-10-09T01:07:43.610

Cheers man. Whats the procedure for changing this without doing a re-install of sql express. – Simon – 2010-10-09T02:11:59.670

1

@Simon - connect in SSMS and follow http://aspadvice.com/blogs/name/archive/2008/04/03/Enabling-Mixed-Mode-Authentication-in-SQL-Server.aspx then change the password for sa by connecting in SSMS again and under the server expand out "Security" and then "Logins". Right click "sa" and select "Properties".

– ta.speot.is – 2010-10-09T02:16:13.367

Excellent link/advice. Followed that, changed to mixed mode. Changed pw for sa, got a 15513 error, but got around this by ticking on 'map to credential' Restarted server - got a bad login via my jar file. Tried creating a new user with un - test, pw - test, still get a bad login error via my JAR. Any other thoughts? – Simon – 2010-10-09T05:31:22.947

@Simon - Try logging in using the test account in SSMS, it gives more verbose error messages. Paste the error message here. – ta.speot.is – 2010-10-09T05:40:36.667

1

Check that your protocols are enabled in Start\Microsoft SQLServer\Configuration tools\Configuration manager.

On the task bar to the left, select SQL Server Network Configuration, and enable Shared Memory, Named Pipes and TCP/IP.

Select SQL Server Services and restart SQL Server Browser and SQL Server.

See if that helps

Barry

Posted 2010-10-09T00:13:03.540

Reputation: 11