QueryableExtensions.AsNoTracking Method

Entity Framework 6.0
 

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

NameDescription
System_CAPS_pubmethodSystem_CAPS_staticAsNoTracking(IQueryable)

Returns a new query where the entities returned will not be cached in the DbContext or ObjectContext. This method works by calling the AsNoTracking method of the underlying query object. If the underlying query object does not have an AsNoTracking method, then calling this method will have no affect.

System_CAPS_pubmethodSystem_CAPS_staticAsNoTracking<T>(IQueryable<T>)

Returns a new query where the entities returned will not be cached in the DbContext or ObjectContext. This method works by calling the AsNoTracking method of the underlying query object. If the underlying query object does not have an AsNoTracking method, then calling this method will have no affect.

Return to top

QueryableExtensions.AsNoTracking Method (IQueryable)

Returns a new query where the entities returned will not be cached in the DbContext or ObjectContext. This method works by calling the AsNoTracking method of the underlying query object. If the underlying query object does not have an AsNoTracking method, then calling this method will have no affect.

public static IQueryable AsNoTracking(
	this IQueryable source
)

Parameters

source
Type: System.Linq.IQueryable

The source query.

Return Value

Type: System.Linq.IQueryable

A new query with NoTracking applied, or the source query if NoTracking is not supported.

Return to top

QueryableExtensions.AsNoTracking<T> Method (IQueryable<T>)

Returns a new query where the entities returned will not be cached in the DbContext or ObjectContext. This method works by calling the AsNoTracking method of the underlying query object. If the underlying query object does not have an AsNoTracking method, then calling this method will have no affect.

public static IQueryable<T> AsNoTracking<T>(
	this IQueryable<T> source
)
where T : class

Parameters

source
Type: System.Linq.IQueryable<T>

The source query.

Return Value

Type: System.Linq.IQueryable<T>

A new query with NoTracking applied, or the source query if NoTracking is not supported.

Type Parameters

T

The element type.

Return to top
Show: