Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...


When to use Single, SingleOrDefault, First and FirstOrDefault?



When to use Single, SingleOrDefault, First and FirstOrDefault?..

Answer / Manoj Kumar Ram

Use Single or SingleOrDefault when you expect only one result and want either an exception thrown (Single) or the default value returned (SingleOrDefault). Use First or FirstOrDefault when you expect more than one result, but need only the first one.

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More LINQ Language-Integrated Query Interview Questions

What is lambda expression in linq c#?

1 Answers  


What is linq in c# with example?

1 Answers  


Why can not datareader by returned from a web services method?

1 Answers  


Explain what is linq?

1 Answers  


Which assembly represents the core LINQ API?

1 Answers  


Explain Union, Intersect and Except?

1 Answers  


When to use Single, SingleOrDefault, First and FirstOrDefault?

1 Answers  


Explain what is lambda expressions in linq?

1 Answers  


What is difference between IEnumerable and IList?

1 Answers  


Why linq is required?

1 Answers  


Why do we need linq?

1 Answers  


What is linq and lambda expressions?

1 Answers  


Categories