Query Syntax vs Method Syntax

While working on an IQueryable<T> provider I was having a problem when doing LINQ statements via the Query Syntax that wasn’t happening when using the Method Syntax (chained lambda expressions).
And that problem has lead to an observation I…

While working on an IQueryable<T> provider I was having a problem when doing LINQ statements via the Query Syntax that wasn’t happening when using the Method Syntax (chained lambda expressions).
And that problem has lead to an observation I made about LINQ, well, about Expression-based LINQ (ie – something implementing IQueryable, so LINQ to SQL, etc).
I’ll use LINQ to SQL for the examples as it’s more accessible to everyone.


Print Share Comment Cite Upload Translate
APA
Posts on LINQ to Fail | Sciencx (2024-03-29T09:15:20+00:00) » Query Syntax vs Method Syntax. Retrieved from https://www.scien.cx/2009/05/19/query-syntax-vs-method-syntax/.
MLA
" » Query Syntax vs Method Syntax." Posts on LINQ to Fail | Sciencx - Tuesday May 19, 2009, https://www.scien.cx/2009/05/19/query-syntax-vs-method-syntax/
HARVARD
Posts on LINQ to Fail | Sciencx Tuesday May 19, 2009 » Query Syntax vs Method Syntax., viewed 2024-03-29T09:15:20+00:00,<https://www.scien.cx/2009/05/19/query-syntax-vs-method-syntax/>
VANCOUVER
Posts on LINQ to Fail | Sciencx - » Query Syntax vs Method Syntax. [Internet]. [Accessed 2024-03-29T09:15:20+00:00]. Available from: https://www.scien.cx/2009/05/19/query-syntax-vs-method-syntax/
CHICAGO
" » Query Syntax vs Method Syntax." Posts on LINQ to Fail | Sciencx - Accessed 2024-03-29T09:15:20+00:00. https://www.scien.cx/2009/05/19/query-syntax-vs-method-syntax/
IEEE
" » Query Syntax vs Method Syntax." Posts on LINQ to Fail | Sciencx [Online]. Available: https://www.scien.cx/2009/05/19/query-syntax-vs-method-syntax/. [Accessed: 2024-03-29T09:15:20+00:00]
rf:citation
» Query Syntax vs Method Syntax | Posts on LINQ to Fail | Sciencx | https://www.scien.cx/2009/05/19/query-syntax-vs-method-syntax/ | 2024-03-29T09:15:20+00:00
https://github.com/addpipe/simple-recorderjs-demo