AVGKEY
Syntax
<avgkey-expression> := 'AVGKEY(' <Key> { ',' <Value> } ')'
Since
2.2.6
Return-type
Key
Description
The AVGKEY function returns the key of the first argument with the result for the expression passed as the second argument beeing the nearest to the average value of all results. If any of the arguments is NULL the function returns NULL.
Examples
AVGKEY( PRODUCT, Amount() )
Returns the product with the closest amount to the average value over all products (for the current filter).
See also
MAXKEY, MINKEY
