Hadoop: key and value are tab separated in the output file. how to do it semicolon-separated?

Bob picture Bob · Jun 14, 2012 · Viewed 15.6k times · Source

I think the title is already explaining my question. I would like to change

key (tab space) value

into

key;value

in all output files the reducers are generating from the output of mappers.

I could not find good documentation on this using google. Can anyone please give a fraction of code on how to achieve this?

Answer

Chris White picture Chris White · Jun 14, 2012

Set the configuration property mapred.textoutputformat.separator to ";"