Database Reference
In-Depth Information
grunt> ILLUSTRATE max_temp;
-------------------------------------------------------------------------------
| records | year:chararray | temperature:int |
quality:int |
-------------------------------------------------------------------------------
| | 1949 | 78 |
1 |
| | 1949 | 111 |
1 |
| | 1949 | 9999 |
1 |
-------------------------------------------------------------------------------
-------------------------------------------------------------------------------
| filtered_records | year:chararray | temperature:int |
quality:int |
-------------------------------------------------------------------------------
| | 1949 | 78 |
1 |
| | 1949 | 111 |
1 |
-------------------------------------------------------------------------------
-------------------------------------------------------------------------------
| grouped_records | group:chararray |
filtered_records:bag{:tuple( |
year:chararray,temperature:int, |
quality:int)} |
-------------------------------------------------------------------------------
| | 1949 | {(1949, 78, 1), (1949, 111,
1)} |
-------------------------------------------------------------------------------
---------------------------------------------------
| max_temp | group:chararray | :int |
---------------------------------------------------
| | 1949 | 111 |
---------------------------------------------------
Notice that Pig used some of the original data (this is important to keep the generated
dataset realistic), as well as creating some new data. It noticed the special value 9999 in
the query and created a tuple containing this value to exercise the FILTER statement.
In summary, the output of ILLUSTRATE is easy to follow and can help you understand
what your query is doing.
Search WWH ::




Custom Search