作者:余枫
1
问题重现
1.在 MySQL 中建表,一个bigint字段,二个varchar字段
2.在Hive中建Parquet表
create table test(s1 string comment '字段1',s2 string comment '字段2',s3 string comment '字段3') comment '测试表'stored as parquet;
3.使用Sqoop从MySQL导入数据到HDFS,要导入的目录是Hive中新建表的数据目录
sqoop import --connect jdbc:mysql://192.168.0.178:3306/test --username root --password 123456 --query "select cast(\`s1\