Results 1 to 6 of 6
  1. #1
    Join Date
    Dec 2007
    Posts
    288

    Unanswered: Problem connecting with SQLServer driver for JDBC

    One of the programmers has a JAVA APP and is trying to connect to a Database on one of my SQL Server Instances. SQL Server 2000 Standard SP4

    Getting this error: CAN ANYONE HELP?

    java.sql.SQLException: [Microsoft][SQLServer 2000 Driver for JDBC]Error establishing socket.
    at com.microsoft.jdbc.base.BaseExceptions.createExcep tion(Unknown Source)
    at com.microsoft.jdbc.base.BaseExceptions.getExceptio n(Unknown Source)
    at com.microsoft.jdbc.base.BaseExceptions.getExceptio n(Unknown Source)
    at com.microsoft.jdbc.sqlserver.tds.TDSConnection.<in it>(Unknown Source)
    at com.microsoft.jdbc.sqlserver.SQLServerImplConnecti on.open(Unknown Source)
    at com.microsoft.jdbc.base.BaseConnection.getNewImplC onnection(Unknown Source)
    at com.microsoft.jdbc.base.BaseConnection.open(Unknow n Source)
    at com.microsoft.jdbc.base.BaseDriver.connect(Unknown Source)
    at java.sql.DriverManager.getConnection(DriverManager .java:582)
    at java.sql.DriverManager.getConnection(DriverManager .java:185)
    at DBConnection.<init>(DBConnection.java:45)
    at IDMLabUpd.run(IDMLabUpd.java:32)
    at IDMLabUpd.main(IDMLabUpd.java:18)

  2. #2
    Join Date
    Jan 2007
    Location
    UK
    Posts
    11,434
    Provided Answers: 10
    Connection string please
    George
    Home | Blog

  3. #3
    Join Date
    Dec 2007
    Posts
    288
    SQLconn.user=Tower
    SQLconn.pass=TowerPilotODBC
    SQLconn.drivername=com.microsoft.jdbc.sqlserver.SQ LServerDriver
    SQLconn.dbURL=jdbc:microsoft:sqlserver://KOCTOWERDEV02:1412

    I checked my Server Properties and TCP\IP is enabled and listening on port 1412.

  4. #4
    Join Date
    Dec 2007
    Posts
    288
    Also, this is my connection string:

    SQLconn.user=Tower
    SQLconn.pass=TowerPilotODBC
    SQLconn.drivername=com.microsoft.jdbc.sqlserver.SQ LServerDriver
    SQLconn.dbURL=jdbc:microsoft:sqlserver://KOCTOWERDEV02:1412

    I checked my Server Properties and TCP\IP is enabled and listening on port 1412.

  5. #5
    Join Date
    Sep 2005
    Posts
    161
    Do you have the most recent jdbc driver from Microsoft? Version 1.2 uses a different class name and url. It works with SQL Server 2000.

    com.microsoft.sqlserver.jdbc.SQLServerDriver
    jdbc:sqlserver://<server>

  6. #6
    Join Date
    Dec 2007
    Posts
    288
    awesome. Thank you!

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •