Page 1 of 1

applying indexes in LINQ query

Posted: Wed 13 Oct 2010 10:10
by raghavendra
how can i apply a table index present in the database in my linq query while querying through entity framework.

Thanks,
Raghavendra.

Posted: Wed 13 Oct 2010 11:58
by AndreyR
In case if you are using Entity Framework v4 you can use the ExecuteStoreQuery method.
And you can write your queries in the form of Stored Procedures and create Function Imports for them no matter what EF version you are using.
If you do not have the grants to modify the database you can create CommandTexts instead.