hadoop - Escape character while doing Sqoop export -
i'm trying export hive table oracle using sqoop export command. hive table have fields delimited '|' , escaped '\'.sqoop export jobs failing while parsing records delimiter escaped fields. tried setting 'escaped-by' option.it seems not working.is there way specify escape characters sqoop export. below command tried.
sqoop export \ --connect jdbc:oracle:thin:@//testserver:1521/testschema \ --username user \ --password pwd \ --table test \ --direct \ --escaped-by \\ \ --fields-terminated-by '|' \ --input-lines-terminated-by '\n' \ --export-dir /user/etl/test/
your command has issue. should use --input-fields-terminated-by '|' instead of using --fields terminated '|'.
Comments
Post a Comment