Support Questions
Find answers, ask questions, and share your expertise

How to make pig scripts should choose both hcatalog and tez???

Solved Go to solution

How to make pig scripts should choose both hcatalog and tez???

Rising Star

I would like to know what are the different ways to enable hcatalog and tez in writing pig scripts.

1 ACCEPTED SOLUTION

Accepted Solutions
Highlighted

Re: How to make pig scripts should choose both hcatalog and tez???

Super Guru

@Suresh Bonam

To use both the options, use below command:

pig -useHCatalog -x tez -f script.pig

To use only Hcat:

pig -useHCatalog -f script.pig

To use only tez:

pig -x tez -f script.pig

View solution in original post

4 REPLIES 4
Highlighted

Re: How to make pig scripts should choose both hcatalog and tez???

Super Guru

@Suresh Bonam

To use both the options, use below command:

pig -useHCatalog -x tez -f script.pig

To use only Hcat:

pig -useHCatalog -f script.pig

To use only tez:

pig -x tez -f script.pig

View solution in original post

Highlighted

Re: How to make pig scripts should choose both hcatalog and tez???

Rising Star

@Kuldeep Kulkarni

Is there any way like ,Using "set" in directly grunt shell???

eg: set exectype=tez;
Highlighted

Re: How to make pig scripts should choose both hcatalog and tez???

Super Guru

@Suresh Bonam

Unfortunately No! Either we need to pass it via command line or set "exectype=tez" in pig.properties via Ambari

Highlighted

Re: How to make pig scripts should choose both hcatalog and tez???

Mentor

you can enable hcatalog commands in pig programmatically, use the steps in the following article https://community.hortonworks.com/questions/1954/hcatbin-is-not-defined-define-it-to-be-your-hcat-s....