128
Apache Pig CEIL Function
The Apache Pig CEIL function is used to round up the provided value to the nearest integer. It returns the smallest integer greater than or equal to a given value.
Syntax
Example of CEIL Function
In this example, we round up each value exist in the file to the nearest integer.
Steps to execute CEIL Function
- Create a text file in your local machine and insert the values.
- Check the values inserted in the text files.
- Upload the text files on HDFS in the specific directory.
- Open the pig MapReduce run mode.
- Load the file that contains the data.
- Now, execute and verify the data.
- Let’s round up all the values that exist in the text file.
Here, we got the desired output.
Next TopicFLOOR Function