Using Entity Framework 6.1, I have a scenario in which the entities I am going to query should be mapped to SQL table-valued-functions. During the model creation we can use the .ToTable("TableName") method to map the entities to tables (or views). Is there a way in which I can get the entities to be mapped to functions passing a constant parameter which only depends on the DataContext?
Thank you.
Here is some useful links for Support for Table Valued Functions in EF6 Code First and this on How to use table valued function in entity framework code first approach and a nuget package EntityFramework.CodeFirstStoreFunctions for doing this.