Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

ESQL in Entity Framework

Is there any good and, if possible, exhaustive documentation about ESQL in entity framework ?

I'm trying to make a select of an entity object with modification of a property using a method; something like this :

SELECT foo FROM context.foo WHERE foo.Price = AddTaxes(foo.Price)
like image 938
eka808 Avatar asked Aug 23 '26 15:08

eka808


1 Answers

There is msdn providing some documentation Entity SQL Language

You can also combine it with Linq2Entities with something like

context.foo
    .Where("it.Price == @Price", new ObjectParameter[] 
    { new ObjectParameter("Price", AddTaxes(price) } ).ToList()
like image 171
moi_meme Avatar answered Aug 26 '26 22:08

moi_meme



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!