cancel
Showing results for 
Search instead for 
Did you mean: 
Warehousing & Analytics
Engage in discussions on data warehousing, analytics, and BI solutions within the Databricks Community. Share insights, tips, and best practices for leveraging data for informed decision-making.
cancel
Showing results for 
Search instead for 
Did you mean: 

Connect to Databricks SQL Endpoint using Programming language

Mat
New Contributor III

Hi, I would like to know whether there is a feasibility/options available to connect to databricks sql endpoint using a programming language like java/scala/c#. I can see JDBC URL, but would like to whether it can be considered as any other jdbc connection string to execute a query and get the result.

4 REPLIES 4

Mat
New Contributor III

"Further to current Question(Not an answer 😞 )": Even 'Databricks SQL Connector', I can see this is available only for Python. Is there any databricks sql connector options available for scala/java/c# to execute query outside the databricks cluster to get the data. ?

Håkon_Åmdal
New Contributor III

Hi. As you say, you can use JDBC/ODBC to connect to the SQL endpoints with the drivers supplied by Databricks [1] [2]. For the programming language you want to use, use a JDBC interface/library to connect to the endpoints. For Java, this is built in [3]. For other languages, like python or go, you can use pyodbc [4] and alexbrainman/odbc [5] respectively.

[1] https://databricks.com/spark/jdbc-drivers-download

[2] https://databricks.com/spark/odbc-drivers-download

[3] https://www.javatpoint.com/java-jdbc

[4] https://github.com/mkleehammer/pyodbc

[5] https://github.com/alexbrainman/odbc

Atanu
Databricks Employee
Databricks Employee

I think databricks connect will be feasible solution. https://docs.databricks.com/dev-tools/databricks-connect.html and JDBC driver also be an option. Please let me know if this helps. @Mathavan Mani​ 

StephanieAlba
Databricks Employee
Databricks Employee

Connect with Databricks Users in Your Area

Join a Regional User Group to connect with local Databricks users. Events will be happening in your city, and you won’t want to miss the chance to attend and share knowledge.

If there isn’t a group near you, start one and help create a community that brings people together.

Request a New Group