-
Notifications
You must be signed in to change notification settings - Fork 83
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
active directory authentication and temp table error #278
Comments
I highly recommend not using the The default driver for SQL Server is the official Microsoft JDBC driver. As far as I can tell this should support Active Directory authentication as described here. By either providing a JDBC connection string with appropriate parameters, or by specifying the connectionDetails <- createConnectionDetails(
dbms = "sql server",
server = Sys.getenv("SQL_SERVER"),
user = "EXT19616221@hustietoallas.fi",
password = Sys.getenv("SQL_PASSWORD"),
extraSettings = "authentication=ActiveDirectoryPassword" would work, although I cannot test it myself. Please also don't use |
@salmarachidi : this error message seems unrelated to how you specify the password. Perhaps your IT department can help you figure out the correct connection details when connecting using JDBC? (Such as the correct port) |
@schuemie We fixed the connection details, and it is showing "Connecting using SQL Server driver". But then error: "Failed to load MSAL4J Java library". When I try to fix this with jar files and jaddClassPath, I get other missing java libraries. Is there not a jar file that contains all the dependencies we need? |
@eric-fey-hus did you download the driver using the downloadJdbcDrivers method? See this article |
Yes. I tried that earlier without success. Can try again tomorrow. But I would need a java 11 version. The download is java 8, at least the one I get. |
To my knowledge all JAR files should work with Java 8, but I certainly could have missed something. I suspect MSAL4J is a library needed especially to enable the Active Directory authentication (See https://learn.microsoft.com/en-us/entra/msal/java/) . Adding this jar to the same place where the driver JAR files are should solve this problem. For the JDBC driver version that is installed by |
@schuemie @ginberg Trying to get the java dependencies to work became to complicated. Instead, I fixed the source code of DatabaseConnector. In function I could create a branch on the DatabaseConnector repo to show you exactly what I did? |
Hi @eric-fey-hus. Glad you got it working! I would welcome a pull request. Would you mind forking the repo and create the PR from there? |
For Darwin we have a data partner that is using active directory authentication to setup their connection to sql server and they are getting an error when creating a temp table. In the error their UID is mentioned as schema name..
Is this connection setup supported by DatabaseConnector?
The text was updated successfully, but these errors were encountered: