?
Solved

jdbc:sqlserver driver

Posted on 2012-04-05
2
Medium Priority
?
431 Views
Last Modified: 2012-04-06
hello:
I am trying to map a SQL server 2008r2:
and this is the convention I found on the net:

jdbc:sqlserver://server:port;DatabaseName=dbname

so I fill in:

jdbc:sqlserver://MyMachine\SQL Instance name:1433; XYZ=?????

The question is this:
DatabaseName=dbname - are not those the same (why would I put dbabasename=dbname)?

Is placing the IP of the machine better than  placing MyMachine\SQL Instance name ?


Thank you.
0
Comment
Question by:noamco36
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 84

Assisted Solution

by:Dave Baldwin
Dave Baldwin earned 1000 total points
ID: 37813061
If you are doing this from Java, you should "Request Attention" and get the Java zones added to your question.  They would be more familiar with the jdbc driver.  I believe that 'DatabaseName' is the name of the parameter and 'dbname' should be the name of your database.
0
 
LVL 24

Accepted Solution

by:
johanntagle earned 1000 total points
ID: 37815065
I think you're mixing it up.   I believe you either use jdbc:sqlserver://[serverName[\instanceName]:port OR jdbc:sqlserver://server_ip_or_hostname:port;databaseName=dbname

databaseName is a parameter, and dbname is the value you give it i.e. databaseName=XYZ
0

Featured Post

Veeam Task Manager for Hyper-V

Task Manager for Hyper-V provides critical information that allows you to monitor Hyper-V performance by displaying real-time views of CPU and memory at the individual VM-level, so you can quickly identify which VMs are using host resources.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

In part one, we reviewed the prerequisites required for installing SQL Server vNext. In this part we will explore how to install Microsoft's SQL Server on Ubuntu 16.04.
In this blog post, we’ll look at how using thread_statistics can cause high memory usage.
Via a live example, show how to extract information from SQL Server on Database, Connection and Server properties
Viewers will learn how the fundamental information of how to create a table.

765 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question