-
Notifications
You must be signed in to change notification settings - Fork 433
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Not able to connect to localDB from java connection string #1157
Comments
Hi @satscreate, connection to localDB requires named pipe support, and support for named pipes is in our backlog but there is no timeline for it at this time. You can refer to #769 and #1150 for the discussion that took before. I'll close this issue as duplicate. |
Meantime any workaround available?? @peterbae |
Unfortunately, other than the suggestions made in #769, there is no workaround for this. |
@peterbae I mean you meant this?? This should work? connectionUrl = "jdbc:sqlserver://localhost\SQLEXPRESS;databaseName=myDb;integratedSecurity=true"; |
"jdbc:sqlserver://localhost\SQLEXPRESS..." should be "jdbc:sqlserver://localhost\\SQLEXPRESS...", but otherwise it should work. Edit: I didn't realize two backslashes in the comment also turns into one backslash on GitHub, so you have your connection string correct. |
@peterbae tried below but seems getting error, Test1: Error:
Test2: Error:
Test3: Error:
Test4
But when i try login to localhost\SQLEXPRESS in sql studio, and created dummy database in it, Test5: (This works) Test6: (This not working) |
@satscreate , you are still trying against LocalDB, which is not supported by the driver. You need to install SQL Server Express or any other SQL Server edition that supports TCP/IP. |
Driver version
6.2.2.jre8
SQL Server version
Microsoft SQL Server Management Studio 11.0.2100.60
Microsoft Data Access Components (MDAC) 10.0.14393.0
Microsoft MSXML 3.0 6.0
Microsoft Internet Explorer 9.11.14393.0
Microsoft .NET Framework 4.0.30319.42000
Operating System 6.3.14393
Client Operating System
JAVA/JVM version
1.8.152
Table schema
Java code
Error
Problem description
Getting above exveption. But i checked online and below protocol config is missing at the same time,

Please help and let me know how to enable port and why the protocol for sqlexpress or instance is missing.
But ,

The text was updated successfully, but these errors were encountered: