cancel
Showing results forย 
Search instead forย 
Did you mean:ย 
Data Engineering
Join discussions on data engineering best practices, architectures, and optimization strategies within the Databricks Community. Exchange insights and solutions with fellow data engineers.
cancel
Showing results forย 
Search instead forย 
Did you mean:ย 

spark databricks jdbc driver integration return rows having column names as values

manohar3
New Contributor III

Hi all,

i am using below to code to query table but query returns rows having column names as values

spark.read
.format("jdbc")
.option("url", "jdbc:databricks://acme.cloud.databricks.com:443/myschema;transportMode=http;ssl=1;httpPath=<httppath>;AuthMech=3;UID=token;PWD=<token>;")
.option("dbtable", "mytable")
.load().show()

+---+---------+
|key|value|
+---+---------+
|key|value|
|key|value|
|key|value|
|key|value|

jdbc driver version is 2.6.36

note that odbc driver works but i dont support struct, map, array as column names .


 

1 ACCEPTED SOLUTION

Accepted Solutions

manohar3
New Contributor III
2 REPLIES 2

manohar3
New Contributor III

any idea what causing this? please note that above query i am running from standalone spark application also when i run above in databricks notebook i see expected result

manohar3
New Contributor III

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