0

I have been using superset to query an external table through hive. This table has columns which are mostly of hive complex data types like the struct. How would I write a query in SQL LAB that does something like below?

SELECT header.guid
FROM table1
WHERE guid = 'xxxx'

where header is of struct data type and guid is a member of the header.

The problem as far as I can see is that pyhive maps the struct data types to string, although not sure how to get around it yet

TylerH
  • 20,799
  • 66
  • 75
  • 101
Joseph
  • 698
  • 5
  • 12

1 Answers1

0

I got this working by querying hive through prestodb. PrestoDB needed additional parquet config in it's etc/catalog/hive.properties catalog:

connector.name=hive-hadoop2
hive.metastore.uri=thrift://<hive_url>:9083
hive.parquet-optimized-reader.enabled=true
hive.parquet-predicate-pushdown.enabled=true
Joseph
  • 698
  • 5
  • 12