Skip to content

Instantly share code, notes, and snippets.

@harschware
Created May 15, 2018 22:22
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save harschware/6c0912feaf1851d4a4329066cd253188 to your computer and use it in GitHub Desktop.
Save harschware/6c0912feaf1851d4a4329066cd253188 to your computer and use it in GitHub Desktop.
Livy result for schema using %json magick
{
"code": "import org.apache.spark.sql._\nvar d = sqlContext.sql(\"SELECT tbl10.`venueid`, tbl10.`venuename`, tbl10.`venuecity`, tbl10.`venuestate`, tbl10.`venueseats`, tbl10.`processing_dttm` AS `venues_processing_dttm` FROM `concerts`.`venues` tbl10\")\nvar e = d.schema\n%json e\n",
"id": 7,
"output": {
"data": {
"application/json": [
{
"dataType": {},
"metadata": {
"map": {}
},
"name": "venueid",
"nullable": true
},
{
"dataType": {},
"metadata": {
"map": {}
},
"name": "venuename",
"nullable": true
},
{
"dataType": {},
"metadata": {
"map": {}
},
"name": "venuecity",
"nullable": true
},
{
"dataType": {},
"metadata": {
"map": {}
},
"name": "venuestate",
"nullable": true
},
{
"dataType": {},
"metadata": {
"map": {}
},
"name": "venueseats",
"nullable": true
},
{
"dataType": {},
"metadata": {
"map": {}
},
"name": "venues_processing_dttm",
"nullable": true
}
]
},
"execution_count": 7,
"status": "ok"
},
"progress": 1.0,
"state": "available"
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment