Newer Version Available

This content describes an older version of this product. View Latest

max()

Returns the maximum value of a measure or date field.

Use max() on measure or date fields. Returns the maximum measure or the most recent date in the field.

Example - Find the Largest Opportunity for Each Account

1q = load "Ops";
2q = group q by 'Account_Name';
3q = foreach q generate 'Company' as 'Company', max('Amount') as 'Largest Deal';