DAvg Function Example

This example returns the average freight cost for large orders shipped to the United Kingdom.  The domain is an Orders table.  The criteria part restricts the data by making the expression apply only to records in which Ship Country equals UK and Order Amount is greater than 1000.

X = DAvg("[Freight]", "Orders", "[Ship Country] = 'UK' And [Order Amount] > 1000")