Can't connect to Sql Server database with Netb

2019-08-04 08:03发布

问题:

I'm trying to make a connection database SQL Server 2012 with Netbeans 8.2

Using the connection wizard I select Sql Server 2012 and enter the credentials and fields.

However I get the message that a connection cannot be established.

You can see screenshots of the entered fields: Full Resolution

回答1:

You will need an entry for 'Integrated Security' in your database URL. My connection string, which works, is as follows:

jdbc:sqlserver://localhost\ComputerName:1433;databaseName=DatabaseName;integratedSecurity=true;

Change your entry for 'integratedSecurity' to false in your case, if you are using mixed mode authentication, and it should work OK.