You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@pig.apache.org by Patcharee Thongtra <Pa...@uni.no> on 2014/05/14 11:11:57 UTC

store to defined filename

Hi,

Is it possible to store results in to a file with determined filename, 
instead of part-r-00000? How to do that?

Patcharee

Re: store to defined filename

Posted by Mohammad Tariq <do...@gmail.com>.
Hi there,

You could do that with the help of
MultipleOutputFormat<http://hadoop.apache.org/docs/current/api/org/apache/hadoop/mapred/lib/MultipleOutputFormat.html>class.
It extends FileOutputFormat,and allows us to write the output data
to different output files.

*Warm regards,*
*Mohammad Tariq*
*cloudfront.blogspot.com <http://cloudfront.blogspot.com>*


On Fri, May 16, 2014 at 2:46 AM, Raviteja Chirala <ra...@gmail.com>wrote:

> You can either do Hadoop "mv" if its a wrapper script or
>
> do getMerge to merge and rename all part files to single part file.
>
> On May 14, 2014, at 2:11 AM, Patcharee Thongtra <Pa...@uni.no>
> wrote:
>
> > Hi,
> >
> > Is it possible to store results in to a file with determined filename,
> instead of part-r-00000? How to do that?
> >
> > Patcharee
>
>

Re: store to defined filename

Posted by Raviteja Chirala <ra...@gmail.com>.
You can either do Hadoop "mv" if its a wrapper script or 

do getMerge to merge and rename all part files to single part file. 

On May 14, 2014, at 2:11 AM, Patcharee Thongtra <Pa...@uni.no> wrote:

> Hi,
> 
> Is it possible to store results in to a file with determined filename, instead of part-r-00000? How to do that?
> 
> Patcharee