linq-expressions
Combine several similar SELECT-expressions into a single expression
How to combine several similar SELECT-expressions into a single expression? private static Expression<Func<Agency, AgencyDTO>> CombineSelectors(params Expression<Func<Agency, Agency[详细]
2023-03-09 14:42 分类:问答Calling (params object[]) with Expression[]
I\'m trying to call String.Format from with in a Linq.Expression tree. Here\'s a quick example: var format = Expression.Constant(\"({0}) {1}\");[详细]
2023-03-07 23:44 分类:问答How to convert Expression<Func<T, object>> to Expression<Func<object, object>>
Is there way to convert Express开发者_JAVA百科ion<Func<T, object>> to Expression<Func<object, object>> ?I\'ve had to do this before...[详细]
2023-03-06 03:23 分类:问答Entity Framework use CompiledQuery but allow runtime filter values
I\'m attempting to refactor a cumbersome LINQ-to-SQL data layer with an entity framework one. The database schema behind the model is big and a typical query might have 20 to 30 Includes. The EF gener[详细]
2023-03-05 19:53 分类:问答How is a Func<T> implicitly converted to Expression<Func<T>>?
I don\'t understand what is happening here: Both of these lines compile: Func<object> func = () => new object();[详细]
2023-03-02 14:20 分类:问答How to build a LambdaExpression from an existing LambdaExpression Without Compiling
I want to combine two LambdaExpressions without compiling them. This is what it looks like if I do compile them:[详细]
2023-02-18 08:03 分类:问答setting private properties of classes
I have some very old code which uses reflection to set properties of objects, e.g something like this:[详细]
2023-02-14 16:17 分类:问答How to log a predicate Expression?
Typically my repositories have logging statements for debugging purposes, allowing me to see values of parameters.Recently I went down the path of creating a generic repository that take predicate Exp[详细]
2023-02-14 11:23 分类:问答Dynamic LINQ - Is There A .NET 4 Version?
I\'m looking to use LINQ for some searching routines and wanted to have some dynamic where clauses.So, for example, if a user wants to search by city or search by state, I would have a dynamic LINQ Wh[详细]
2023-02-14 10:47 分类:问答Can we delete clauses from linq expression?
I was wondering whether it\'s possible 开发者_运维技巧to add/remove a where clause from a linq expression/ query operators.[详细]
2023-02-14 07:04 分类:问答