Share via


EdmFunctions.Average(DbExpression) Method

Definition

Creates a DbFunctionExpression that invokes the canonical 'Avg' function over the specified collection. The result type of the expression is the same as the element type of the collection.

public static System.Data.Entity.Core.Common.CommandTrees.DbFunctionExpression Average (this System.Data.Entity.Core.Common.CommandTrees.DbExpression collection);
static member Average : System.Data.Entity.Core.Common.CommandTrees.DbExpression -> System.Data.Entity.Core.Common.CommandTrees.DbFunctionExpression
<Extension()>
Public Function Average (collection As DbExpression) As DbFunctionExpression

Parameters

collection
DbExpression

An expression that specifies the collection from which the average value should be computed.

Returns

A new DbFunctionExpression that produces the average value.

Applies to