Hive與Sql語言很像,
use 數據庫;
以建一個student表為例:
create table student(id int,name string) row format delimited fields terminated by "\t";
編寫student.txt文件(中間以tab鍵隔開 即 \t )
2 Tiny
3 Fun
4 Mark
5 Yong
load data local inpath "/opt/module/datas/student.txt" into table student;
OK