One feller's views on the state of everyday computer science & its application (and now, OTHER STUFF) who isn't rich enough to shell out for www.myfreakinfirst-andlast-name.com
Using 89% of the same design the blog had in 2001.
FOR ENTERTAINMENT PURPOSES ONLY!!!
Back-up your data and, when you bike,
always wear white.
As an Amazon Associate, I earn from qualifying purchases. Affiliate links in green.
Monday, December 29, 2003
When Microsoft's JDBC for SQL 2k's documentation says:
Microsoft SQL Server 2000 supports multiple instances of a SQL Server database running concurrently on the same server. An instance is identified by an instance name.
To connect to a named instance using a connection URL, use the following URL format:
... it's lying. That'll just net you the ever popular...
java.sql.SQLException: [Microsoft][SQLServer 2000 Driver for JDBC]Error establishing socket
... error.
Just leave out the double backslash and instance name. The port will do you just fine. For example:
strJdbcUrl = "jdbc:microsoft:sqlserver://myServersName:2080"; // instance at port 2080
How do you find out the port for named instances? Apparently the port is taken randomly on first start (versus the standard 1433 for defaults) -- port 2080 above. To find out what port it took, you can port sniff OR, much easier, hit "Start, Programs, Microsoft SQL Server, Server Network Utility", then look at the instance you want, click "TCP/IP" (needs to be in the enabled list), and check out what port's listed. Voila.
Sheesh. When all else fails, read the directions. When the directions fail, try something you still haven't thought of, or at least start Googlin'.
posted by ruffin
at 12/29/2003 12:21:00 PM
The postings on this site are [usually] my own and do not necessarily reflect the views of any employer, past or present, or other entity. About Our Author