Write a query to get the single employee name when there are many employees whose name is "test" in the database ?

 Posted by Akiii on 10/30/2012 | Category: LINQ Interview questions | Views: 5597 | Points: 40
Answer:

var employee = (from h in contextobject.Employee 

where h.EmployeeName == "test"
select h).FirstOrDefault<Employee>();




Thanks and Regards
Akiii


| Alert Moderator 

Comments or Responses

Login to post response