EF.Constant<T>(T) Method
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Within the context of an EF LINQ query, forces its argument to be inserted into the query as a constant expression. This can be used to e.g. integrate a value as a constant inside an EF query, instead of as a parameter, for query performance reasons.
public static T Constant<T> (T argument);
static member Constant : 'T -> 'T
Public Shared Function Constant(Of T) (argument As T) As T
- T
The type of the expression to be integrated as a constant into the query.
- argument
- T
The expression to be integrated as a constant into the query.
The same value for further use in the query.
Note that this is a static method accessed through the top-level EF static type.
Toode | Versioonid |
---|---|
Entity Framework Core | 9.0 |
Toote „Entity Framework“ tagasiside
Entity Framework on avatud lähtekoodiga projekt. Tagasiside andmiseks valige link: