Error connecting to the database: No suitable driver found

Description

In context.xml I have:

<Resource name="NAVISIONdb"
auth="Container" type="javax.sql.DataSource"
username="***"
password="*****"
driverClassName="net.sourceforge.jtds.jdbc.Driver"
url="jdbc:jtds:sqlserver://server.netic.dk:1433/Netic_drift"
maxActive="20"
maxIdle="10"
validationQuery="select 1"
/>

Trying to make the same source in CF++ I get:

Error connecting to the database: No suitable driver found for jdbc:jtds:sqlserver://server.netic.dk:1433/Netic_drift

Environment

None

Activity

Show:
Deniz Oğuz
November 27, 2018, 2:18 PM
Edited

could you try without jtds part, like jdbc:sqlserver://

We bundle mssql-jdbc driver with the add-on.

Normann P. Nielsen
November 28, 2018, 6:43 AM

I will look into the mssql-jdbc.

This:

jdbc:sqlserver://server.netic.dk:1433/Netic_drift

gives:

Error connecting to the database: The port number 1433/Netic_drift is not valid.

Normann P. Nielsen
November 28, 2018, 6:57 AM

OK, after looking at https://docs.microsoft.com/en-us/sql/connect/jdbc/building-the-connection-url?view=sql-server-2017

This works (as in I can save):

jdbc:sqlserver://server.netic.dk:1433;databaseName=Netic_drift

Normann P. Nielsen
November 28, 2018, 7:17 AM
Edited

Hm, I have a somewhat strange situation. The field is not present at Edit mode:

But in read mode it has the first result of the query (NETIC FLEX on all issues after I created the field (I would suppose they were "NULL")

Normann P. Nielsen
November 28, 2018, 11:23 AM

Uh @Deniz... Seems I have mis-interpered the usage of the field... Its a "read only" display ting...
OK. It works then...

Fixed

Assignee

Deniz Oğuz

Reporter

Normann P. Nielsen

Labels

None

Source

None

Jira Version

None

Database Type/Version

None

Browser Type/Version

None

Priority

Minor
Configure