In mapreduce,groupby operation performed at
reducer side and filter,projection can be implemented in the map phase.pig
latin also provides standard-operation similar to mapreduce like orderby and
filters,group by..etc.we can analyze pig script and know data flows ans also
early to find the error checking.pig Latin is much lower cost to write and
maintain than Java code for MapReduce.