Where to see the mapreduce code generated from hadoop pig statements

自古美人都是妖i 提交于 2019-12-22 09:30:10

问题


We all know that the hadoop pig statements are converted into java mapreduce code. I want to know there is any way i can see the mapreduce code generated from pig statements ?


回答1:


We all know that hadoop pig statements are converted into java mapreduce code

This is not the case. Hadoop Pig statements are not translated into Java MapReduce code.

A better way of thinking about it is Pig code is "interpreted" in an Pig interpreter that runs in Java MapReduce. Think about it this way: Python and Perl do not "generate" C code, they run through a C program (interpreter) that executes the instructions. Basically, Pig provides a framework for a query plan to be executed. The Pig code gets interpreted and a prebuilt interpreter MapReduce job executes it. For this reason, this is impossible to do.

If you want to understand more of what is going on, use EXPLAIN and ILLUSTRATE to get some insight on the query plan that Pig built to execute your code.



来源:https://stackoverflow.com/questions/11133029/where-to-see-the-mapreduce-code-generated-from-hadoop-pig-statements

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!