Created on 03-13-2016 10:54 AM
ex- grunt >OrderedData = order studentDetails by age;
This will sort by default in ASC order.
Otherwise We can mention here as below:
OrderedData = order studentDetails by age DESC;
OrderedData = order studentDetails by age ASC;
Created on 06-17-2016 03:43 AM
Yes ascending is usually a default in most languages.
https://pig.apache.org/docs/r0.14.0/basic.html#order-by
Note: ORDER BY is NOT stable; if multiple records have the same ORDER BY key, the order in which these records are returned is not defined and is not guarantted to be the same from one run to the next.