DbRawSqlQuery<TElement>.MaxAsync Method

 

Asynchronously returns the maximum value of the query.

Namespace:   System.Data.Entity.Infrastructure
Assembly:  EntityFramework (in EntityFramework.dll)

NameDescription
System_CAPS_pubmethodMaxAsync()

Asynchronously returns the maximum value of the query.

System_CAPS_pubmethodMaxAsync(CancellationToken)

Asynchronously returns the maximum value of the query.


DbRawSqlQuery<TElement>.MaxAsync Method ()

Asynchronously returns the maximum value of the query.

public Task<TElement> MaxAsync()

Return Value

Type: System.Threading.Tasks.Task<TElement>

A task that represents the asynchronous operation. The task result contains the maximum value in the query result.

Multiple active operations on the same context instance are not supported. Use 'await' to ensure that any asynchronous operations have completed before calling another method on this context.


DbRawSqlQuery<TElement>.MaxAsync Method (CancellationToken)

Asynchronously returns the maximum value of the query.

public Task<TElement> MaxAsync(
	CancellationToken cancellationToken
)

Parameters

cancellationToken
Type: System.Threading.CancellationToken

A CancellationToken to observe while waiting for the task to complete.

Return Value

Type: System.Threading.Tasks.Task<TElement>

A task that represents the asynchronous operation. The task result contains the maximum value in the query result.

Multiple active operations on the same context instance are not supported. Use 'await' to ensure that any asynchronous operations have completed before calling another method on this context.