hive export import命令

 EXPORT TABLE stu_p TO '/stu_p.dat'; 将数据和元数据导出到hdfs hdfs dfs -ls /stu_p.dat/year=2012
导入表(必须明白导出表,导出表是将表的元数据,数据导出到hdfs上.)讲一个导出的表导入到数据库中,这个hdfs_path 是一个导出表的文件夹
import table tbname from ‘hdfs_path’
6、导入作为一个外部表
export table department to 'hdfs_exports_location/department';
import external table department from 'hdfs_exports_location/department';
原文地址:https://www.cnblogs.com/rocky-AGE-24/p/7152565.html