How to export data from hive into hdfs in spark program?
Hi all:I wonder if is there a way to export data from table of hive into hdfs using spark?like this: INSERT OVERWRITE DIRECTORY '/user/linqili/tmp/src' select * from $DB.$tableName
Re: How to export data from hive into hdfs in spark program?
This depends on which output format you want. For Parquet, you can simply do this: |hiveContext.table(some_db.some_table).saveAsParquetFile(hdfs://path/to/file) | On 12/23/14 5:22 PM, LinQili wrote: Hi Leo: Thanks for your reply. I am talking about using hive from spark to export data from