DbSchema Database Designer - Sqlserver JDBC Driver

DbSchema is a Sqlserver database designer which is using Java JDBC drivers to connect to Sqlserver. You may simply download and install DbSchema to get the Sqlserver JDBC driver and test the connection to Sqlserver. DbSchema can be evaluated 15 days for free. The driver can be then find in the DbSchema installation folder or in the home directory '.DbSchema' folder. In this way you will be also able to test the graphical diagrams, visual query builder, relational data browse and more.

Download DbSchema

About JDBC Drivers

JDBC drivers are Java library files with the extension .jar used by all Java applications to connect to the database. Usually they are provided by the same company which implemented the Sqlserver software. DbSchema installation kit already include an Sqlserver driver.

Each JDBC driver is using a specific URL. The URL is a string passed to the driver, formatted in a way which is decided by the team who bild the driver, and which usually includes information about the database host, port and database name.

SqlServer JDBC Driver

DbSchema can connect to Azure Cloud database ! Just connect using host 'servername.database.windows.net', port 1433 and configured user and password.

We support all versions of SqlServer including SqlServer 2014, under the name 'SqlServer'. For SqlServer 2000-2005 we have created a different entry in DbSchema because of compatibility problems with the versions after. You can download the JDBC driver right here. Unzip the downloaded zip file to get the driver jars.
Download Sqlserver JDBC driver

Please write us if this version of the driver is not the latest, we will update it !


Driver Information :

  • Required File(s): sqlserver.jar
  • Java Driver Class: com.microsoft.jdbc.sqlserver.SQLServerDriver
  • URL: jdbc:sqlserver://{HOST}:{PORT};databaseName={DB}
  • Website: Microsoft

jTDS JDBC Driver

Download the jtds-nn-dist.zip file, unzip it and then load the jtds.jar file
  • Required File(s): jtds-1.2.2.jar
  • Java Driver Class: net.sourceforge.jtds.jdbc.Driver
  • URL: jdbc:jtds:sqlserver://{HOST}[:{PORT}][/{DB}];user={USER};password={PASSWORD}[;instance={PARAM}] or jdbc:jtds:sqlserver://{HOST}[:{PORT}][/{DB}];domain={PARAM};integratedSecurity=true
  • Website: jTDS web site
Watch a You Tube video How to configure SqlServer 2008 for jdbc connections.

How to enable TCP/IP Connection and Set The Port

SqlServer TCP/IP connections are not enabled by default. You won't be able to connect to the database unless you enable them.

In the SQLServer Configuration Manager go to Protocols and enable TCP/IP

Click on the protocols for SqlExpress, right-click on the TCP/IP and choose Properties.
Go to the IP Addresses tab, scroll to the bottom and you'll find the option IP All enter the desired port by default it should be 1433.


Enable Database Authentication (Mixed Mode)

By default only the Windows Authentication is enabled. This will allow login on the database only using the COMPUTER_DOMAIN/WINDOWS_USER and not using the 'sa' user. Read the chapter about how to install SqlServer for details.

To be able to connect to the database using the 'sa' user or other database user, the mixed authentication mode should be enabled.

Take this steps to enable mixed mode authentication:

First, login to your server. Click on Start > Programs > Microsoft SQL Server Select "SQL Server Management Studio Express" / "SQL Server Management Studio", depending on your version of SQL Server.

Right click the server name and select "Properties". Click "Security".

A dialog will open. Under "Server authentication" select "SQL Server and Windows Authentication Mode".

Right click the server name and select "Restart". Wait a few moments for the service to restart before proceeding.

To review the current configured authentication method, from the previous dialog 'Server Properties' choose the 'View Connection Properties' in the bottom. In the Properties Dialog the configured authentication will show up.

Debug Connectivity Issues

  1. Check Network:
    Make sure the Network is workable and stable when you connect to SQL Server on a remote machine. You can test the Network connection using the PING grogram: ping <Server Name>
  2. Enable remote connections for SQL Server:
    a) In SQL Server Configuration Manager, expand SQL Server Network Configuration, and then click Protocols for .
    b) In the details pane, right-click one of the available protocols, and then click Properties.
    c) To enable the TCP/IP protocol (or named pipes) for remote connections, set the Enabled box to Yes.
  3. Enable the SQL Server Browser service:
    If you connect to a named instance, make sure the SQL Server Browser service by using SQL Server Configuration Manager is enable or specify the TCP port when connecting to it.
  4. Create an exception for SQL Server in Windows Firewall:
    If firewall is enabled on the server, you need to put TCP port number of the instance, such as 1433 for the default instance. Then add UDP 1434 for SQL Server Browser Service.
For TCP / IP connectivity problem troubleshooting process as below, please follow the steps.
  1. Check the server name you used.
    For a named instance, you need to type computer name\instance name. For a default server, you only need to type computer name. For server Configuration, please use netstat command. Run “netstat -an”command in DOS windows. The "netstat-an" command output in the removal of the part of the SQL Server port number as following: Active Connections Proto Local Address Foreign Address State TCP 0.0.0.0:1433 0.0.0.0:0 LISTENING TCP 169.254.173.244:1433 169.254.173.244:3952 ESTABLISHED
  2. Client TCP/IP configuration
    In most cases you do not need to configure the client, because the TCP / IP protocol is enabled by default. You can use the Client Network Utility (or SQL Server Configuration Manger) to configure TCP / IP protocol. Run cliconfg.exe or from Start -> Programs -> Microsoft SQL Server -> Client Network Utility can be transferred out
  3. Verify that SQL Server is actually listening for TCP / IP protocol
    In order to verify that SQL Server does monitor the TCP / IP protocol, but also need to see the SQL Server errorlog file. If you find that SQL Server does not listen for TCP / IP protocol, use the server-side network configuration tool (run svrnetcn.exe ) to confirm whether the configured SQL Server monitor TCP / IP protocol.
  4. Check the network connectivity.
    To ensure that only the server can ping the IP address of SQL Server, SQL Server can ping the server name. If you ping the server name in question, indicating the DNS or WINS server configuration problem, you can in your HOSTS file (HOSTS file in the system32 \ drivers \ etc directory) and manually add server IP address as follows: 169.254.173.244 MySQLserver If you have a problem with ping IP address, then check the configuration of the network including hardware connections. On the server and client are using "ipconfig / all" command to check the server and client are on the same network.
  5. Use the TELNET command to check the SQL listening port.
    To verify that SQL Server listening port, you can use the TELNET command. Assume that SQL Server's IP address is 192.168.1.1, port 1234, you can run the following command: TELNET 192.168.1.1 1234 If the TELNET successful, then the result will be a only a black screen with cursor in flash. If unsuccessful, then you will get an error message. These error messages need to continue troubleshooting the issue. From the remote machine can you telnet to SQL server on the port SQL server is running. On remote machine, open command prompt and type: telnet SQLServerHostName is either IP address or hostname of the remote computer where SQL serve is running PortNumber is port number SQL server is listening for default instance it is 1433 but check SQL server configuration manager to make sure.
  6. Check the SQL Server login user access.
  7. You can try to specify protocol and port to connect SQL Server in the Query Analyzer as below:
    TCP:MySQLServer,1433 Through this method can force the specified query analyzer using the TCP / IP connection to the server specified port.
  8. If it does not work for you, please try to use Network Monitor to capture trace to analysis.
    For more information about Network Monitor, please refer to this article
Additional, please refer the articles as below:
  1. TCP/IP port numbers required to communicate to SQL over a firewall: http://support.microsoft.com/?id=287932
  2. How to Troubleshoot Basic TCP/IP Problems: http://support.microsoft.com/kb/169790

Connect to Sqlserver from DbSchema

Start DbSchema, choose 'Connect to database' and in the connection dialog choose 'Sqlserver' from the database combo. There you can upload the JDBC driver. For a limited list of databases the drivers are already included.

Next step is to fill in the connection dialog the database host, port, username and password.

  • The host is the name or the IP address of the machine where the database is running. If the database is running on the same machine as DbSchema, this will be localhost.
  • The port is a number, a kind of 'door' where the database listen for requests. This has a default value which DbSchema will set for you. If the database administrator choose a different port, you may have to enter the correct value
  • Database username is the user to login into the database. DbSchema may enter by default the most user for each database. If this is not correct, check the database documentation for this. Usually during Sqlserver installation you are informed about the username.
  • Database password for the database user, is set inside the database.
DbSchema will replace this values in the JDBC URL string, will send this to server and try to connect.

Connect to Sqlserver using DbSchema database tool

Connectivity Troubleshooting

If you get problems connecting to database, please remember :
  • Windows Firewall may block the communication. You may need to reconfigure or disable it.
  • Remote connections are not always enabled by default. MySql lets you, for example, to enable them during the database software installation.
  • Make sure the host is reachable. From the connection dialog you can ping the database host ensure the configured port is reachable.
  • Check the driver version is compatible with the database software. It may be that DbSchema provided JDBC driver is not the latest version. Please inform us in this case.
Learn more about how to connect to database from the DbSchema help.
 
DbSchema Video Presentation

DbSchema Diagrams for Sqlserver

Database diagram

DbSchema is an Sqlserver designer, featuring interactive diagrams, relational data browse and editor, visual query builder, query editor, random data generator, forms and reports and more.

Read more »

Get Started for Free

Sqlserver Relational Data Browse

Relational Data Browse

An amazingly simple data explorer that offers simultaneous views of data from multiple tables and features numerous filters, data sorting mechanisms, and much more.


Read more »

Sqlserver Visual Query Builder

Query Builder

Graphically SQL query editor, with different joins, exists, where clauses and group by. The query is represented as a diagram, simple and intuitive to use.


Read more »

Sqlserver Schema Synchronization

Database Schema Synchronization

DbSchema holds its own image of the schema. This can be synchronized against any database, modification scripts can be generated.


Read more »

Sqlserver HTML 5 Documentation

HTML5 Documentation

Generate HTML documentation including the vector diagram image. The image is interactive, move the cursor over column names or columns to read the comments.


Read more »

Navigation