How do I find out from command line (Unix) if the the server is able to connect to the SQL server database.
You can ping the port. That’s about all you can do.
You can also try and connect using WmDB package. Pretty easy and fast as well.
I’m not sure exactly what you are attempting to do.
If you are trying to isolate a problem that you are having attempting to connect a JDBC Adapter Connection to your SQL Server database, you could write a simple java application that connects to the server and executes a simple SQL statement.
If this test client doesn’t work, you probably have a network or DB server configuration issue. If it does work, then your JDBC Adapter Connection or your WmDB alias should work inside IS assuming your classes are in the classpath.
I attached a simple connectivity test client that does the above for Sybase 12.5 using the Sybase JConnect 5.5 Type IV JDBC driver.
I added comments to the code to show what you changes you would have to make to get this to work with MS SQL Server (I don’t have a SQL Server handy to test this).
SybaseJDBCConnectivityTest.java (2.9 k)