[ 
https://issues.apache.org/jira/browse/PIG-2965?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13760313#comment-13760313
 ] 

Dmitriy V. Ryaboy commented on PIG-2965:
----------------------------------------

A UDF essentially has a constructor and an exec method. "foreach lines 
udf(foo)" calls the exec method and passes to it the foo parameter. "define 
udfinstance udf(foo)" passes foo to the constructor, and makes an instance of 
the foo udf initialized in that way bound to "udfinstance" (so you can have 
many differently initialized udfs in the same script).  You can read more info 
on all this in the docs about "define" keyword and the UDF author's guide.
                
> RANDOM should allow seed initialization for ease of testing
> -----------------------------------------------------------
>
>                 Key: PIG-2965
>                 URL: https://issues.apache.org/jira/browse/PIG-2965
>             Project: Pig
>          Issue Type: Bug
>            Reporter: Aneesh Sharma
>            Assignee: Jonathan Coveney
>              Labels: newbie
>         Attachments: PIG-2965-0.patch
>
>


--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

Reply via email to