Apache Pig Introduction
Apache Pig Environment
Pig Latin
Load & Store Operators
Diagnostic Operators
- Apache Pig - Illustrate Operator
- Apache Pig - Explain Operator
- Apache Pig - Describe Operator
- Apache Pig - Diagnostic Operator
Grouping & Joining
- Apache Pig - Cross Operator
- Apache Pig - Join Operator
- Apache Pig - Cogroup Operator
- Apache Pig - Group Operator
Combining & Splitting
Filtering
Sorting
Pig Latin Built-In Functions
- Apache Pig - Math Functions
- Apache Pig - date-time Functions
- Apache Pig - String Functions
- Apache Pig - Bag & Tuple Functions
- Load & Store Functions
- Apache Pig - Eval Functions
Other Modes Of Execution
Apache Pig Useful Resources
Selected Reading
- Who is Who
- Computer Glossary
- HR Interview Questions
- Effective Resume Writing
- Questions and Answers
- UPSC IAS Exams Notes
Apache Pig - Eval Functions
Apache Pig provides various built-in functions namely eval, load, store, math, string, bag and tuple functions.
Eval Functions
Given below is the pst of eval functions provided by Apache Pig.
S.N. | Function & Description |
---|---|
1 | To compute the average of the numerical values within a bag. |
2 | To concatenate the elements of a bag into a string. While concatenating, we can place a depmiter between these values (optional). |
3 | To concatenate two or more expressions of same type. |
4 | To get the number of elements in a bag, while counting the number of tuples in a bag. |
5 | It is similar to the COUNT() function. It is used to get the number of elements in a bag. |
6 | To compare two bags (fields) in a tuple. |
7 | To check if a bag or map is empty. |
8 | To calculate the highest value for a column (numeric values or chararrays) in a single-column bag. |
9 | To get the minimum (lowest) value (numeric or chararray) for a certain column in a single-column bag. |
10 | Using the Pig Latin PluckTuple() function, we can define a string Prefix and filter the columns in a relation that begin with the given prefix. |
11 | To compute the number of elements based on any Pig data type. |
12 | To subtract two bags. It takes two bags as inputs and returns a bag which contains the tuples of the first bag that are not in the second bag. |
13 | To get the total of the numeric values of a column in a single-column bag. |
14 | To sppt a string (which contains a group of words) in a single tuple and return a bag which contains the output of the sppt operation. |