DZone Forums
Go Back   DZone Forums > Community > Databases & SQL > Microsoft SQL Server
Reload this Page Connection String For Microsoft SQLServer
Notices
Reply
 
LinkBack Thread Tools Display Modes
  (#1 (permalink)) Old
Member
 
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
Join Date: Jan 2009
Default Connection String For Microsoft SQLServer - 01-12-2009, 06:14 AM

When I connect to MSSQL using Visual Studio [Language c#]...I use this connection string :
String JO = "Data Source=PEARL\\JAGA_2;Database=WOLF;user id=sa ;password='starlet';Pooling=False";


When I connect to MSSQL using NETBEANs i use this connection-String :
Class.forName("com.microsoft.sqlserver.jdbc.SQLSer verDriver");
String connectionUrl = "jdbc:sqlserver://localhost:1433;" +
"databaseName=BOOM;user=sa;password='starlet'; ";


Here is the question .
How can NetBeans know which SqlServer instance to access ?
[since I did not specify it in the connection string]
[infact I wrote Data source:=PEARL\\JAGA_2 ONLY in connectionString for Visual Studio...not for NetBeans]



Regards



P.S.
Can anydody translate the connectiion String at the TOP[the one I wrote for Visual Studio] into a valid connection string that I can use in NetBeans ?
Thanks
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Connecting To Microsoft SQL Server-2008 jo90way Microsoft SQL Server 0 01-12-2009 04:48 AM
How can Microsoft best enagage with ISVs and Start-ups? guntherlenz Startups & VC 0 06-24-2008 10:06 AM
String to formatted date sahuabinash Java 1 04-29-2008 11:03 PM
String and Arry Problem farakhkhan@yahoo.com Java 2 04-14-2008 02:54 AM
find and install hangs when no internet connection saleeb Eclipse 3 03-15-2008 03:03 PM


Copyright 1997-2009, DZone, Inc.
vBulletin Skin developed by: vBStyles.com