Reputation: 2338
In Databricks , we are able to access the ADLS file based on the following authentication code in Python mode .But when I tried to Authenticate for SQL mode getting below error . Please help us to get information on how to declare authentication in sql.
Python :
spark.conf.set("fs.azure.account.key.<your-storage-account-name>.dfs.core.windows.net","<access-key>")
df = spark.read.csv("abfss://<your-file-system-name>@<your-storage-account-name>.dfs.core.windows.net/<your-directory-name>/<your-file-name>")
Sql: reference:
Upvotes: 0
Views: 212
Reputation: 87154
you're using incorrect syntax. variables should be set with SET
keyword, like:
SET fs.azure.account.key.<your-storage-account-name>.dfs.core.windows.net = <access-key>;
after that you could run your query.
Upvotes: 1