sqoop 从sqlserver导入到hive因为列名是中文导致报错,报错信息如下:
17/05/04 17:26:28 INFO hive.metastore: Connected to metastore. 17/05/04 17:26:28 ERROR sqoop.Sqoop: Got exception running Sqoop: org.kitesdk.data.ValidationException: Field names are not alphanumeric (plus '_'): anlysprojectsale.月份, anlysprojectsale.美发_卡异动, anlysprojectsale.美容_卡异动, anlysprojectsale.美发_销卡服务_大项, anlysprojectsale.美发_销卡服务_小项, anlysprojectsale.美发_销卡产品, anlysprojectsale.美容_销卡服务_大项, anlysprojectsale.美容_销卡服务_小项, anlysprojectsale.美容_销卡产品, anlysprojectsale.美发_现金服务_大项, anlysprojectsale.美发_现金服务_小项, anlysprojectsale.美发_现金产品, anlysprojectsale.美容_现金服务_大项, anlysprojectsale.美容_现金服务_小项, anlysprojectsale.美容_现金产品 org.kitesdk.data.ValidationException: Field names are not alphanumeric (plus '_'): anlysprojectsale.月份, anlysprojectsale.美发_卡异动, anlysprojectsale.美容_卡异动, anlysprojectsale.美发_销卡服务_大项, anlysprojectsale.美发_销卡服务_小项, anlysprojectsale.美发_销卡产品, anlysprojectsale.美容_销卡服务_大项, anlysprojectsale.美容_销卡服务_小项, anlysprojectsale.美容_销卡产品, anlysprojectsale.美发_现金服务_大项, anlysprojectsale.美发_现金服务_小项, anlysprojectsale.美发_现金产品, anlysprojectsale.美容_现金服务_大项, anlysprojectsale.美容_现金服务_小项, anlysprojectsale.美容_现金产品 at org.kitesdk.data.ValidationException.check(ValidationException.java:55) at org.kitesdk.data.spi.Compatibility.checkSchema(Compatibility.java:118) at org.kitesdk.data.spi.Compatibility.checkDescriptor(Compatibility.java:132) at org.kitesdk.data.spi.hive.HiveManagedMetadataProvider.create(HiveManagedMetadataProvider.java:44) at org.kitesdk.data.spi.hive.HiveManagedDatasetRepository.create(HiveManagedDatasetRepository.java:81) at org.kitesdk.data.Datasets.create(Datasets.java:239) at org.kitesdk.data.Datasets.create(Datasets.java:307) at org.apache.sqoop.mapreduce.ParquetJob.createDataset(ParquetJob.java:141) at org.apache.sqoop.mapreduce.ParquetJob.configureImportJob(ParquetJob.java:119) at org.apache.sqoop.mapreduce.DataDrivenImportJob.configureMapper(DataDrivenImportJob.java:130) at org.apache.sqoop.mapreduce.ImportJobBase.runImport(ImportJobBase.java:260) at org.apache.sqoop.manager.SqlManager.importTable(SqlManager.java:692) at org.apache.sqoop.manager.SQLServerManager.importTable(SQLServerManager.java:163) at org.apache.sqoop.tool.ImportTool.importTable(ImportTool.java:507) at org.apache.sqoop.tool.ImportTool.run(ImportTool.java:615) at org.apache.sqoop.Sqoop.run(Sqoop.java:143) at org.apache.hadoop.util.ToolRunner.run(ToolRunner.java:70) at org.apache.sqoop.Sqoop.runSqoop(Sqoop.java:179) at org.apache.sqoop.Sqoop.runTool(Sqoop.java:218) at org.apache.sqoop.Sqoop.runTool(Sqoop.java:227) at org.apache.sqoop.Sqoop.main(Sqoop.java:236)
请问如上错误怎么解决啊,谢谢。
|