hadoop-mapreduce-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ksgupta misc <ksgupta.m...@gmail.com>
Subject How to sort key,value pair by value(In ascending)
Date Wed, 14 Sep 2011 00:44:21 GMT
Hi,

I have the content like
*10103*,1042279,*4*
*10070*,1001089,*5*
*10102*,1015504,*7*
*10080*,1024369,*7*
*10050*,1025671,*1*
...
from which i separated the key,value pairs and got the output after a single
map and reduce as follows:

10050  1
10070  5
10080  7
10102  7
10103  4
...

I require to sort the output<key,value> pair by value (In ascending order).
Please let me know how can i go ahead.

Required output:
10050  1
10103  4
10070  5
10080  7
10102  7

Thanks in advance,
--Shashi

Mime
View raw message