Skip to content

How does presto read local files in parquet format #18182

Answered by majetideepak
jiangjiguang asked this question in Q&A
Discussion options

You must be logged in to vote

@jiangjiguang there is an undocumented hive connector feature where you can set the following config and use a local directory as the catalog.

hive.metastore=file
hive.metastore.catalog.dir=file:/mnt/hive_data/

Now, you have to create a table say customer using the parquet file schema.
You will see a folder with this table name /mnt/hive_data/customer
Then move your parquet file to this folder. You should be able to query the Parquet file.

We should also have a formal way in Presto to read local Parquet/ORC files. I will look into formalizing the hive.metastore=file.

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by StevenMih
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants