0
votes

I am trying to learn both java and pig programming.. So basically.. not an ideal combination but things are looking good.. but I am not able to solve this out..

In my local environment I dont have pig libraries... but on the cluster... YES!

So.. when I do

     import org.apache.pig.EvalFunc;

It is always red lined.. for obvious reasons..

So basically, do i just ignore it and just create a jar file??

or do i do a local download of pig.. import libraries.. write a code.. and then create a jar file.. and then run it?

Any suggestions.. Thanks.

1

1 Answers

3
votes

In order to compile and package your jar, you will have to download the pig jars. Make sure to download the same pig version as on your cluster and it should work fine.

You can also use Maven (or another build tool) to build your UDFs and reference pig as a dependency, Maven will take care of downloading the dependencies.