How To Do A Multi-Column Join In LINQ

This is an exclusive guest post from Shaun Tirubeni, please visit his blog located here for more of his work.

Since we live in a complex world, creating even a simple application takes a fair amount of effort. We do multi-column joins every day using SQL. Many companies are moving away from raw SQL and stored procedures to ORMs and other layers of abstraction.

Read more “How To Do A Multi-Column Join In LINQ”

LINQ Expression – how to append to an expression at a later stage

The cool thing with LINQ and Entity framework is that if you pass an expression through to you context, it creates an SQL Query based of that expression to fetch the data you need, instead of fetching loads of data down and having to sift through them in C#.

A recurring issue that plagued me was that if I needed to pass through a slightly different LINQ expressions based on certain conditions it looked like I was repeating code, and I don’t like repeating code.

after a few hours of playing around with different techniques I devised a little way to append to an expression.
Read more “LINQ Expression – how to append to an expression at a later stage”