facebook

Can’t connect to local SQL Server via Database Explorer

  1. MyEclipse Archived
  2.  > 
  3. Database Tools (DB Explorer, Hibernate, etc.)
Viewing 6 posts - 31 through 36 (of 36 total)
  • Author
    Posts
  • #266931 Reply

    alababi
    Member

    I’m having trouble connecting to the SQL database too, I use MS SQL jtds driver downloaded from http://sourceforge.net, here is the link: http://nchc.dl.sourceforge.net/sourceforge/jtds/jtds-1.2-dist.zip

    My SQL Server name: ALA on local machine
    I use “sa” as admin user and a blank password, I had also create another user to test but fail,
    my connection URL is: jdbc:jtds:sqlserver//:ALA:1434/master
    I’ve tried another URL too, but all them failed, hic
    jdbc:jtds:sqlserver//:ALA:1434/master
    jdbc:jtds:sqlserver//:localhost:1434/master
    jdbc:jtds:sqlserver//:ALA:1433/master
    jdbc:jtds:sqlserver//:localhost:1433/master

    Here is some picture I print the screen ’bout the error:


    #266943 Reply

    Haris Peco
    Member

    alababi,

    You need a URL of the form jdbc:jtds:sqlserver//:localhost:1434/master or jdbc:jtds:sqlserver//:localhost:1433/master
    However, your error means that your database is not listening on port 1434 (or 1433).You have to set this (default is off) using SQL Server Configuration Manager.
    You will see nodes Protocols and Protocol TCP/IP – right click on TCP/IP and in the IP Address tab set TCP port to your favored port.

    Regards,
    Peco

    #267034 Reply

    alababi
    Member

    Thanks Peco, it’s working now, My friend Khoa adviced me to upgrade to SQL 2000 SP4 and it worked.
    I have another problem while I use Driver downloaded from http://microsoft.com, here is 3 file I have downloaded: msbase.jar, mssqlserver.jar, msutil.jar
    When I tried to connect, it shows this message (I used this connection string: jdbc:sqlserver://localhost:1433 ,I checked, port 1433 is opened, jdbc:microsoft:sqlserver://localhost:1433/master fail as well, hic hic)

    #267035 Reply

    Haris Peco
    Member

    alababi,

    Could you try Microsoft JDBC driver 2005.It will works with MS SQL 2000 as well.
    This is link for download http://msdn2.microsoft.com/en-us/data/aa937724.aspx

    Regards,

    #267069 Reply

    alababi
    Member

    Hey, it’s working, thank you Peco, it helped me much. I hate these bugs, it costs me lots times.

    #267096 Reply

    Haris Peco
    Member

    alababi,

    I’m glad for your success.You are correct, setting databases is complex, because we have to support different databases and installing database servers is out of our control.JDBC driver settings is complicated as well and it is little easier in new specificaton (jdbc 4.0 and jdk 6), but there isn’t drivers for new specification.

    Regards,
    Peco

Viewing 6 posts - 31 through 36 (of 36 total)
Reply To: Can’t connect to local SQL Server via Database Explorer

You must be logged in to post in the forum log in