http://www.entityframeworktutorial.net/Querying-with-EDM.aspx Querying with EDM: We have created EDM, DbContext, and entity classes in the previous sections. Here, you will learn the different types of queries an entity framework supports, which is in turn converted into SQL query for the underlaying database. Entity framework supports three types of queries: 1) LINQ to Entities, 2) Entity SQL, and 3) Native SQL LINQ to Entities: Language-Integrated Query (LINQ) is a powerful query language introduced in Visual Studio 2008. You can use LINQ in C# or Visual Basic to query different data sources. LINQ-to-Entities operates on entity framework entities to access the data from the underlying database. You can use LINQ method syntax or query syntax when querying with EDM. Visit LINQ Tutorials to learn LINQ step-by-step. LINQ Method syntax: //Querying with LINQ to Entities using ( var context = new SchoolDBEntities ()) { var L2EQuery = context...
Comments
Post a Comment