Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

extend linq to entities to recognize custom methods

As discussed here and in countless more: I'd like to know if there is ANY way to inherit/extend/... Entity Framework 4.1 to translate a custom method to SQL.

like image 874
Vincent Vancalbergh Avatar asked Apr 03 '12 11:04

Vincent Vancalbergh


1 Answers

No. But you if you are using EDMX, you can either use model defined function or custom SQL / mapped SQL function exposed as .NET method available in Linq-to-Entities query.

None of these techniques is available with code-first.

like image 63
Ladislav Mrnka Avatar answered Sep 25 '22 00:09

Ladislav Mrnka