Or look into the MultipleFileOutput/MultipleTextOutputFormat classes. They provide a method, generateFileNameForKeyValue(), that allows the format to return arbitrary output filenames for given key/value pairs. It's deprecated in 0.20.0, but works well enough as far as I've seen.
Dan Young -----Original Message----- From: Jothi Padmanabhan [mailto:[email protected]] Sent: Monday, June 15, 2009 12:35 AM To: [email protected] Subject: Re: Could I output results into multiple files in hadoop ? Would org.apache.hadoop.mapred.lib.MultipleOutputs help? Jothi > ________________________________ > From: Kunsheng Chen <[email protected]> > To: [email protected] > Sent: Sunday, June 14, 2009 7:18:31 PM > Subject: Could I output results into multiple files in hadoop ? > > > Hi, everyone, > > Is there any way to output the results in Reduce to different files ? > > > thanks in advance, > > -Kun > > >
