作者:aa杨钦佳_170 | 来源:互联网 | 2018-06-06 02:41
如果你指定了n为sqoop导入的换行符,mysql的某个string字段的值如果包含了n,则会导致sqoop导入多出一行记录。有一个选项-hive-drop-import-delimsDropsn,r,and1fromstringfieldswhenimportingtoHive.
如果你指定了\n为sqoop导入的换行符,mysql的某个string字段的值如果包含了\n, 则会导致sqoop导入多出一行记录。 有一个选项 -hive-drop-import-delims Drops \n, \r, and \01 from string fields when importing to Hive.
如果你指定了\n为sqoop导入的换行符,mysql的某个string字段的值如果包含了\n, 则会导致sqoop导入多出一行记录。
有一个选项
-hive-drop-import-delims Drops \n, \r, and \01 from string fields when importing to Hive.
这样\n \r 和\01都被自动删除,不会捣乱了。