Install
Run the following command to install the connector from the root of your project:
npm install --save @latitude-data/databricks-connector
The sources files must be inside the queries/
folder.
Configuration
To configure the connection with your Databricks database follow these steps:
Create the source `.yaml` file within the `queries` folder if you haven't already
Add the following code for your Databricks connection
type: databricks
details:
host: string
port: number
path: string
clientId: string
token: string
oauthClientId: string
oauthClientSecret: string
Replace the details section with your info and save
Done, now you can test your connection
Attributes
- Host → The internet address of the Databricks cluster, specifying where the cluster is located online.
- Port → (Optional) The network port used for connecting to the Databricks cluster, indicating the communication entry point.
- Path → (Optional) Specifies the location of the workspace or resource on the Databricks host, detailing the specific access path.
- ClientId → (Optional) An identifier for the application connecting to Databricks, used for authentication purposes.
- Token → (Optional) A secret key used by the application to authenticate itself to Databricks.
- OauthClientId → (Optional) An identifier used for OAuth authentication, specifying the application in the OAuth process.
- OauthClientSecret → (Optional) A secret code used in conjunction with OauthClientId for OAuth authentication, verifying the application’s identity.
Test connection
To test the connection you can:
- Create a query
.sql
in the queries
directory that points to a table of your new connection in the FROM
clause. See the section SQL Syntax Basics to learn more.
- Use the command line to run
latitude run query_file_name
where query_file_name
is the name of your .sql
file. This will display the results in your terminal. See the section Running queries to learn more about how to query your data.
Responses are generated using AI and may contain mistakes.