You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@pig.apache.org by Prashanth Pappu <pr...@conviva.com> on 2008/05/12 22:29:27 UTC

PIG built-in functions

I need to use the equivalents of SQL functions FLOOR, CEIL etc in a few PIG
queries.
And I'm looking for a list of complete PIG supported functions.

Is there any such documentation? Else, does anyone know if these functions
are supported?

Prashanth

RE: PIG built-in functions

Posted by Olga Natkovich <ol...@yahoo-inc.com>.
I am working on creating a UDF repository where your UDF and others
would reside.

Olga 

> -----Original Message-----
> From: Arun C Murthy [mailto:arunc@yahoo-inc.com] 
> Sent: Tuesday, May 13, 2008 3:44 PM
> To: pig-user@incubator.apache.org
> Subject: Re: PIG built-in functions
> 
> 
> On May 13, 2008, at 3:15 PM, Prashanth Pappu wrote:
> 
> > Writing the UDF was simple enough. How do I contribute the 
> code back 
> > to Pig?
> >
> 
> Please open a new jira (https://issues.apache.org/jira/secure/ 
> CreateIssue!default.jspa) and attach your patch there... thanks!
> 
> Arun
> 
> PS: You will need a jira a/c to create a new jira.
> 
> > Another question - I often find that the command 'illustrate' runs  
> > into more
> > heap space issues than a brute-force dump command. Isn't that  
> > contrary to
> > the goal of the Illustrate command - that it should pick a smaller  
> > data-set,
> > use lesser memory/cpu and finish faster?
> >
> > Prashanth
> >
> > On Mon, May 12, 2008 at 5:24 PM, Arun C Murthy <arunc@yahoo- 
> > inc.com> wrote:
> >
> >>
> >> On May 12, 2008, at 4:35 PM, pi song wrote:
> >>
> >>  Sorry I'm stupid. FLOOR, CEIL are not aggregate. You have to  
> >> write a UDF.
> >>>
> >>>
> >> And if you do write one, please contribute it back to Pig! *smile*
> >>
> >> Arun
> >>
> >>
> >>  On 5/13/08, pi song <pi...@gmail.com> wrote:
> >>>
> >>>>
> >>>> I'm sorry to say we don't have FLOOR, CEIL at the moment but I  
> >>>> guest
> >>>> you
> >>>> use MIN/MAX and apply a bit.
> >>>>
> >>>> On 5/13/08, Prashanth Pappu <pr...@conviva.com> wrote:
> >>>>
> >>>>>
> >>>>> I need to use the equivalents of SQL functions FLOOR, CEIL etc  
> >>>>> in a
> >>>>> few
> >>>>> PIG
> >>>>> queries.
> >>>>> And I'm looking for a list of complete PIG supported functions.
> >>>>>
> >>>>> Is there any such documentation? Else, does anyone know if these
> >>>>> functions
> >>>>> are supported?
> >>>>>
> >>>>> Prashanth
> >>>>>
> >>>>>
> >>>>
> >>>>
> >>
> 
> 

Re: PIG built-in functions

Posted by Arun C Murthy <ar...@yahoo-inc.com>.
On May 13, 2008, at 3:15 PM, Prashanth Pappu wrote:

> Writing the UDF was simple enough. How do I contribute the code  
> back to Pig?
>

Please open a new jira (https://issues.apache.org/jira/secure/ 
CreateIssue!default.jspa) and attach your patch there... thanks!

Arun

PS: You will need a jira a/c to create a new jira.

> Another question - I often find that the command 'illustrate' runs  
> into more
> heap space issues than a brute-force dump command. Isn't that  
> contrary to
> the goal of the Illustrate command - that it should pick a smaller  
> data-set,
> use lesser memory/cpu and finish faster?
>
> Prashanth
>
> On Mon, May 12, 2008 at 5:24 PM, Arun C Murthy <arunc@yahoo- 
> inc.com> wrote:
>
>>
>> On May 12, 2008, at 4:35 PM, pi song wrote:
>>
>>  Sorry I'm stupid. FLOOR, CEIL are not aggregate. You have to  
>> write a UDF.
>>>
>>>
>> And if you do write one, please contribute it back to Pig! *smile*
>>
>> Arun
>>
>>
>>  On 5/13/08, pi song <pi...@gmail.com> wrote:
>>>
>>>>
>>>> I'm sorry to say we don't have FLOOR, CEIL at the moment but I  
>>>> guest
>>>> you
>>>> use MIN/MAX and apply a bit.
>>>>
>>>> On 5/13/08, Prashanth Pappu <pr...@conviva.com> wrote:
>>>>
>>>>>
>>>>> I need to use the equivalents of SQL functions FLOOR, CEIL etc  
>>>>> in a
>>>>> few
>>>>> PIG
>>>>> queries.
>>>>> And I'm looking for a list of complete PIG supported functions.
>>>>>
>>>>> Is there any such documentation? Else, does anyone know if these
>>>>> functions
>>>>> are supported?
>>>>>
>>>>> Prashanth
>>>>>
>>>>>
>>>>
>>>>
>>


Re: PIG built-in functions

Posted by Prashanth Pappu <pr...@conviva.com>.
Writing the UDF was simple enough. How do I contribute the code back to Pig?

Another question - I often find that the command 'illustrate' runs into more
heap space issues than a brute-force dump command. Isn't that contrary to
the goal of the Illustrate command - that it should pick a smaller data-set,
use lesser memory/cpu and finish faster?

Prashanth

On Mon, May 12, 2008 at 5:24 PM, Arun C Murthy <ar...@yahoo-inc.com> wrote:

>
> On May 12, 2008, at 4:35 PM, pi song wrote:
>
>  Sorry I'm stupid. FLOOR, CEIL are not aggregate. You have to write a UDF.
> >
> >
> And if you do write one, please contribute it back to Pig! *smile*
>
> Arun
>
>
>  On 5/13/08, pi song <pi...@gmail.com> wrote:
> >
> > >
> > > I'm sorry to say we don't have FLOOR, CEIL at the moment but I guest
> > > you
> > > use MIN/MAX and apply a bit.
> > >
> > > On 5/13/08, Prashanth Pappu <pr...@conviva.com> wrote:
> > >
> > > >
> > > > I need to use the equivalents of SQL functions FLOOR, CEIL etc in a
> > > > few
> > > > PIG
> > > > queries.
> > > > And I'm looking for a list of complete PIG supported functions.
> > > >
> > > > Is there any such documentation? Else, does anyone know if these
> > > > functions
> > > > are supported?
> > > >
> > > > Prashanth
> > > >
> > > >
> > >
> > >
>

Re: PIG built-in functions

Posted by Arun C Murthy <ar...@yahoo-inc.com>.
On May 12, 2008, at 4:35 PM, pi song wrote:

> Sorry I'm stupid. FLOOR, CEIL are not aggregate. You have to write  
> a UDF.
>

And if you do write one, please contribute it back to Pig! *smile*

Arun

> On 5/13/08, pi song <pi...@gmail.com> wrote:
>>
>> I'm sorry to say we don't have FLOOR, CEIL at the moment but I  
>> guest you
>> use MIN/MAX and apply a bit.
>>
>> On 5/13/08, Prashanth Pappu <pr...@conviva.com> wrote:
>>>
>>> I need to use the equivalents of SQL functions FLOOR, CEIL etc in  
>>> a few
>>> PIG
>>> queries.
>>> And I'm looking for a list of complete PIG supported functions.
>>>
>>> Is there any such documentation? Else, does anyone know if these
>>> functions
>>> are supported?
>>>
>>> Prashanth
>>>
>>
>>


Re: PIG built-in functions

Posted by pi song <pi...@gmail.com>.
Sorry I'm stupid. FLOOR, CEIL are not aggregate. You have to write a UDF.

On 5/13/08, pi song <pi...@gmail.com> wrote:
>
> I'm sorry to say we don't have FLOOR, CEIL at the moment but I guest you
> use MIN/MAX and apply a bit.
>
> On 5/13/08, Prashanth Pappu <pr...@conviva.com> wrote:
> >
> > I need to use the equivalents of SQL functions FLOOR, CEIL etc in a few
> > PIG
> > queries.
> > And I'm looking for a list of complete PIG supported functions.
> >
> > Is there any such documentation? Else, does anyone know if these
> > functions
> > are supported?
> >
> > Prashanth
> >
>
>

Re: PIG built-in functions

Posted by pi song <pi...@gmail.com>.
I'm sorry to say we don't have FLOOR, CEIL at the moment but I guest you use
MIN/MAX and apply a bit.

On 5/13/08, Prashanth Pappu <pr...@conviva.com> wrote:
>
> I need to use the equivalents of SQL functions FLOOR, CEIL etc in a few
> PIG
> queries.
> And I'm looking for a list of complete PIG supported functions.
>
> Is there any such documentation? Else, does anyone know if these functions
> are supported?
>
> Prashanth
>