Home | About | Sematext search-lucene.com search-hadoop.com
 Search Hadoop and all its subprojects:

Switch to Threaded View
Pig, mail # user - Strange behaviour when using FLATTEN


Copy link to this message
-
Re: Strange behaviour when using FLATTEN
James Newhaven 2012-04-11, 15:15
Thanks Pablo,

That link was really useful. The reason the fieldnames contain NULL, is
that I used FLATTEN with TOP, which currently discards the bagname. This is
going to be fixed in 0.11 as per
https://issues.apache.org/jira/browse/PIG-2365

On Wed, Apr 11, 2012 at 2:55 PM, pablomar
<[EMAIL PROTECTED]>wrote:

> this is a very good explanation of flatten:
>
>
> http://ofps.oreilly.com/titles/9781449302641/advanced_pig_latin.html#foreach_flatten
>
>
>
> On Wed, Apr 11, 2012 at 9:46 AM, James Newhaven <[EMAIL PROTECTED]
> >wrote:
>
> > Hi,
> >
> > Sorry, this is a PIG newbie question...
> >
> > When I use FLATTEN, I don't understand the structure of the relation that
> > is returned.
> >
> > For example, the following relation A is the result of using flatten:
> >
> > DESCRIBE A;
> >
> > A {null::group: chararray,null::tagcount: long}
> >
> > I'm not really sure why there is "null" prefixing group and tagcount. Can
> > anyone help explain what this means?
> >
> > Thanks,
> > James
> >
>