Error accessing Azure sql from Azure databricks using jdbc authentication=ActiveDirectoryInteractive

Pankaj Mendi 0 Reputation points
2024-05-14T11:35:08.7566667+00:00

Getting below error while accessing Azure sql using jdbc from Azure databricks notebook,

com.microsoft.sqlserver.jdbc.SQLServerException: Failed to authenticate the user p***** in Active Directory (Authentication=ActiveDirectoryInteractive). Unable to open default system browser

Here is the url of jdbc,

url = f"jdbc:sqlserver://{database_host}:{database_port};database={database_name};user={user};password={password};encrypt=true;trustServerCertificate=false;hostNameInCertificate=*.database.windows.net;loginTimeout=30;authentication=ActiveDirectoryInteractive;"
Azure SQL Database
Azure Databricks
Azure Databricks
An Apache Spark-based analytics platform optimized for Azure.
1,982 questions
{count} votes

1 answer

Sort by: Most helpful
  1. Alberto Morillo 33,086 Reputation points MVP
    2024-05-15T03:48:04.8466667+00:00

    Have you configured the Azure SQL firewall to allow access from Azure resources?

    User's image

    This video may help you connect from Azure Databricks to Azure SQL.

    This is the documentation to connect using interactive mode and JDBC.