Alyona Kovalyova
Alyona Kovalyova

Reputation: 119

How to connect to sql DB from soapUI using connection string?

I would like to ask someone who already tried to connect to SQL database from soapUI opensource version.

I have a test step JDBC request where I try to test and connect to my sql database. I use opensource version of soapUI. I read how it should be set up but still experience some problems.

This is what I do: I installed java 8 and jdbc driver version 4.1. Added jdbc jar file to SoapUi/jre/bin folder as it is said in documentation for soapUI. This version of driver should work with Java 8.

Then in Driver field I write

com.microsoft.sqlserver.jdbc.SQLServerDriver

In connection string:

jdbc:sqlserver://Sservername:portnumber;databaseName=Consumption;username=alyona.kovalyova;password=mypassword

I get error saying

Can't get the Connection for specified properties; com.microsoft.sqlserver.jdbc.SQLServerException: Login failed for user 'alyona.kovalyova'. ClientConnectionId...

I use my domain account because in our company the policy does not allow us to use database user. Because of this I tried to add integratedSecurity parameter to the string which should allow to login with windows account like this:

jdbc:sqlserver://S23-AS:1433;databaseName=Consumption;integratedSecurity=true

I also get error:

Can't get the Connection for specified properties; com.microsoft.sqlserver.jdbc.SQLServerException: This driver is not configured for integrated authentication. ClientConnectionId..

Does anyone encountered the same issue before? Could you give some recommendation?

Upvotes: 0

Views: 5561

Answers (1)

Jan
Jan

Reputation: 13858

For integrated authentication to work you'll need sqljdbc_auth.dll matching your environment (32bit / 64bit) in your library path (putting it in bin as well might help already)

Upvotes: 1

Related Questions