Re: LINQ Question (Contains)

Tech-Archive recommends: Repair Windows Errors & Optimize Windows Performance



It's actually not about a generated assembly. It's all static assemblies that compile-once. The extension methods defined in Dynamic.cs parse an expression provided as a simple string into a LINQ expression tree at runtime.

So all they do is take away the burden of us having to do it ourselves. :-)

I assume it scales just fine.

I'm still not happy as obviously this takes us a bit back into not so type safe SQL String Command creation times... however, I'm still struggling with fully understanding how to manually create an expression tree with these dynamics myself.

Hmm... I need a "functional enlightment"... :-)


"Jon Skeet [C# MVP]" <skeet@xxxxxxxxx> wrote in message news:MPG.21b40eb1b8e347ee669@xxxxxxxxxxxxxxxxxxxxxxx
Ralf Rottmann (www.24100.net) <BeSharp@xxxxxxxx> wrote:
I finally found a pretty good solution and documented it here:

http://www.talentgrouplabs.com/blog/archive/2007/11/25/dynamic-linq-q
ueries--dynamic-where-clause-part-1.aspx

What do you think?

Hmm... I worry a little bit about how this will scale over time. I
don't know the details of generated assemblies, but I wonder whether
you'll get a new assembly every time you run a query. Maybe not - I
really haven't looked at the details.

I'm sure there's a way of getting the expression tree stuff to work,
but it's still eluding me at the moment :(

--
Jon Skeet - <skeet@xxxxxxxxx>
http://www.pobox.com/~skeet Blog: http://www.msmvps.com/jon.skeet
World class .NET training in the UK: http://iterativetraining.co.uk

.



Relevant Pages

  • Re: Eval code and AppDomains
    ... Do you know of any other way to Eval a String to get a Boolean result ... > "Joe Fallon" wrote in message ... Rick Strahl's article showed how to create a separate appdomain. ... >>> Based on how other assemblies work with an AppDomain that is correct. ...
    (microsoft.public.dotnet.languages.vb)
  • Re: Eval code and AppDomains
    ... Do you know of any other way to Eval a String to get a Boolean result ... > "Joe Fallon" wrote in message ... Rick Strahl's article showed how to create a separate appdomain. ... >>> Based on how other assemblies work with an AppDomain that is correct. ...
    (microsoft.public.dotnet.framework.aspnet)
  • Re: Eval code and AppDomains
    ... Do you know of any other way to Eval a String to get a Boolean result ... Rick Strahl's article showed how to create a separate appdomain. ... > Based on how other assemblies work with an AppDomain that is correct. ... >> Dim objEval As New EvalProvider ...
    (microsoft.public.dotnet.languages.vb)
  • Re: Eval code and AppDomains
    ... Do you know of any other way to Eval a String to get a Boolean result ... Rick Strahl's article showed how to create a separate appdomain. ... > Based on how other assemblies work with an AppDomain that is correct. ... >> Dim objEval As New EvalProvider ...
    (microsoft.public.dotnet.framework.aspnet)
  • Re: Eval code and AppDomains
    ... Do you know of any other way to Eval a String to get a Boolean result other ... >> Dim objEval As New EvalProvider ... >> Imports Microsoft.VisualBasic ...
    (microsoft.public.dotnet.framework.aspnet)