You are viewing a plain text version of this content. The canonical link for it is here.
Posted to common-user@hadoop.apache.org by Mark Kerzner <ma...@shmsoft.com> on 2012/02/07 15:27:48 UTC

How to set up output field separator?

Hi, all,

I've tried this

configuration.set("map.output.key.field.separator", ",");

but it did not work. How do I set the separator to another field, from its
default "tab"?

Thank you,
Mark

Re: How to set up output field separator?

Posted by Mark Kerzner <ma...@shmsoft.com>.
Harsh,

I think it worked in Hadoop 0.20, but it does not work with the new
mapreduce API, and even this key,
mapreduce.output.textoutputformat.separator, does not help.

Maybe I should switch back to 0.20 for the time being.

Mark

On Tue, Feb 7, 2012 at 10:27 AM, Harsh J <ha...@cloudera.com> wrote:

> That property is probably just for streaming, used with
> KeyFieldBasedComparator/Partitioner.
>
> You may instead set mapred.textoutputformat.separator for the
> TextOutputFormat in regular jobs. Let us know if that works.
>
> On Tue, Feb 7, 2012 at 7:57 PM, Mark Kerzner <ma...@shmsoft.com>
> wrote:
> > Hi, all,
> >
> > I've tried this
> >
> > configuration.set("map.output.key.field.separator", ",");
> >
> > but it did not work. How do I set the separator to another field, from
> its
> > default "tab"?
> >
> > Thank you,
> > Mark
>
>
>
> --
> Harsh J
> Customer Ops. Engineer
> Cloudera | http://tiny.cloudera.com/about
>

Re: How to set up output field separator?

Posted by Harsh J <ha...@cloudera.com>.
That property is probably just for streaming, used with
KeyFieldBasedComparator/Partitioner.

You may instead set mapred.textoutputformat.separator for the
TextOutputFormat in regular jobs. Let us know if that works.

On Tue, Feb 7, 2012 at 7:57 PM, Mark Kerzner <ma...@shmsoft.com> wrote:
> Hi, all,
>
> I've tried this
>
> configuration.set("map.output.key.field.separator", ",");
>
> but it did not work. How do I set the separator to another field, from its
> default "tab"?
>
> Thank you,
> Mark



-- 
Harsh J
Customer Ops. Engineer
Cloudera | http://tiny.cloudera.com/about