How to Give a column name to the Output in MapReduce?

690 Views Asked by At

How to give a column name to the output in MR?
suppose i have a simple text i want to count by using a simple word count program
but i want to get my output with column names is it possible?

1

There are 1 best solutions below

0
On

You can achieve this by overriding setup method of reducer. You can add the custom headers in to the setup method which will be followed by map reduce output.

Follow MR API Doc: http://hadoop.apache.org/docs/stable/api/org/apache/hadoop/mapreduce/Reducer.html