Glinkot
Glinkot

Reputation: 2964

Converting between LINQ expression types

Does anyone know of a tool which converts between the 'types' of linq query expression? ie:

a) var foo = from c in customers select...

b) var foo = customer .Where(...

I'm more familiar with a), but to use dynamic linq b) is required so it'd be nice to easily convert all my existing queries.

I've had a bit of a look at Linqer and LinqPad but can't see such a function - perhaps its in there somewhere.

Thanks

Upvotes: 1

Views: 193

Answers (1)

Enigmativity
Enigmativity

Reputation: 117057

It's definitely in LINQPad - but you only see it when querying against databases:

LINQPad Screenshots

You even get the SQL and IL that was created.

Upvotes: 4

Related Questions