Calling functions in LINQ queries
Short Description
article requieres some previous knowledge of LINQ and C# 3, …. representation of the LINQ query and executes it (for download visit the project …
Website: tomasp.net | Filesize: 82kb
Content
Calling functions in LINQ queries
Tomas Petricek
tomas@tomasp.netThe LINQ project (see [1]) is an extension to .NET Framework and most common
.NET languages (C# and VB.Net) that extends these languages with query operators
and some other features that make it possible to integrate queries in the languages. This
article requieres some previous knowledge of LINQ and C# 3, so I recomend looking at
the the specification at LINQ home page.
1 What is and what isn’t possible
There is a limitation of what you can write in a DLINQ query. This is clear, because
DLINQ queries are translated at runtime to T-SQL statements, so the possibilities of
DLINQ queries are limited by the T-SQL language. Conversion to T-SQL supports
many of standard language constructs, but it can hardly support calling of your
methods for two reasons. First (more important) reason is that the method is compiled
and it is not possible to get its expression tree (as long as you don’t use utility like
Reflector). The second reason is that T-SQL is very limited when compared with C# as I
mentioned earlier, although saying that T-SQL is limited is not fair, because it has…
Get the file Download here
Related Books:Related Searches:
Comments
Leave a Reply