【发布时间】:2016-08-04 20:16:10
【问题描述】:
我有一个以 ctrlB 作为记录分隔符的文件。我能够通过在猪存储中覆盖 LoaderInputFormat 类和 getInputFormat() 方法来读取猪中的文件。但是我无法使用 ctrlB 作为记录分隔符来存储文件。
【问题讨论】:
标签: hadoop mapreduce apache-pig
我有一个以 ctrlB 作为记录分隔符的文件。我能够通过在猪存储中覆盖 LoaderInputFormat 类和 getInputFormat() 方法来读取猪中的文件。但是我无法使用 ctrlB 作为记录分隔符来存储文件。
【问题讨论】:
标签: hadoop mapreduce apache-pig
读取ctrl+b分隔记录
SET textinputformat.record.delimiter '\n'
x= LOAD 'xyz' USING PigStorage('\u0002');
写入ctrl+b分隔记录-
store x into 'y' using PigStorage('\u0002');
【讨论】: