Answers for "entity framework with query c#"

C#
1

entities query in

int[] ids = { 1, 2, 3, 4, 5};

var query = from item in db.myTable
            where ids.Contains(item.ID)
            select item;
Posted by: Guest on November-17-2020
0

entity framework with query c#

using (var ctx = new SchoolDBEntities())
{
    var studentName = ctx.Students.SqlQuery("Select studentid, studentname, standardId from Student where studentname='Bill'").FirstOrDefault<Student>();
} 
//Reference Link
//https://www.entityframeworktutorial.net/Querying-with-EDM.aspx
Posted by: Guest on January-23-2021
0

entity framework with query C#

using (var ctx = new SchoolDBEntities())
{
    var studentName = ctx.Students.SqlQuery("Select studentid, studentname, standardId from Student where studentname='Bill'").FirstOrDefault<Student>();
}    
//https://www.entityframeworktutorial.net/Querying-with-EDM.aspx
//https://www.entityframeworktutorial.net/EntityFramework4.3/raw-sql-query-in-entity-framework.aspx
Posted by: Guest on January-23-2021

Code answers related to "entity framework with query c#"

C# Answers by Framework

Browse Popular Code Answers by Language