-RE: Multiple files as input to a mapreduce job
Subroto Sanyal 2011-09-09, 10:58
The functionality expected by you achieved by Hive (Internally by Mapred).
May be you can take look in Hive Join logics or can use Hive directly.
You can look into org.apache.hadoop.mapred.lib.CombineFileInputFormat<K,V>
and related classes for more details.
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
Sent: Friday, September 09, 2011 11:54 AM
To: [EMAIL PROTECTED]
Subject: Multiple files as input to a mapreduce job
The following is the scenario I have:
I have a java program that reads multiple files from the disk.
* There are 3 files (A,B,C) that are read and populated into 3
* There are 2 files input1 and input2 that act as input to my
* I search a keyword in file input1 and find the ID corresponding to
the matching entries.
* This ID is used in file input2 to fetch the entries corresponding
There has to be a join between input1 and input2
I want to convert it into a map reduce program, is that possible?
How can we read multiple input files in the mapper, can we read files from
This e-mail and any files transmitted with it are for the sole use of the
intended recipient(s) and may contain confidential and privileged
If you are not the intended recipient, please contact the sender by reply
e-mail and destroy all copies of the original message.
Any unauthorised review, use, disclosure, dissemination, forwarding,
printing or copying of this email or any action taken in reliance on this
e-mail is strictly
prohibited and may be unlawful.