That simple. I need to create a View using Code First. I found nothing about this on google nor SO. Is there a way to accomplish this?
I need that view to be created and queried using linq, so it's not a solution to create it using an script on Database creation, for example:
var results = from c in db.Customer
join v in db.MyView on c.Id equals v.Id
select c;
A work around is also acceptable. I need a way to query entities against non-constant/ non-entities values.
See Question&Answers more detail:os