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 "huanchen.zhang" <hu...@ipinyou.com> on 2012/06/11 15:10:48 UTC

only ouput values, no keys, no reduce

hi,

I am developing a map reduce program which has no reduce. And I just want the maps to output all the values which meet some requrements (no keys output).

what should I do in this case? I tried context.write(Text, Text), but it outputs both keys and values.

Thank you !

Best,
Huanchen

2012-06-11 



huanchen.zhang 

Re: only ouput values, no keys, no reduce

Posted by 顾晟 <gu...@gmail.com>.
you can write your own outputformat

2012/6/11, huanchen.zhang <hu...@ipinyou.com>:
> hi,
>
> I am developing a map reduce program which has no reduce. And I just want
> the maps to output all the values which meet some requrements (no keys
> output).
>
> what should I do in this case? I tried context.write(Text, Text), but it
> outputs both keys and values.
>
> Thank you !
>
> Best,
> Huanchen
>
> 2012-06-11
>
>
>
> huanchen.zhang
>


-- 


无论何事,你们愿意人怎样待你们,你们也要怎样待人

Re: only ouput values, no keys, no reduce

Posted by Mark Kerzner <ma...@shmsoft.com>.
You can use Hadoop NullWritable

http://hadoop.apache.org/common/docs/r1.0.1/api/org/apache/hadoop/io/NullWritable.Comparator.html

Mark

On Mon, Jun 11, 2012 at 8:10 AM, huanchen.zhang
<hu...@ipinyou.com>wrote:

> hi,
>
> I am developing a map reduce program which has no reduce. And I just want
> the maps to output all the values which meet some requrements (no keys
> output).
>
> what should I do in this case? I tried context.write(Text, Text), but it
> outputs both keys and values.
>
> Thank you !
>
> Best,
> Huanchen
>
> 2012-06-11
>
>
>
> huanchen.zhang
>