Summary

I know this chapter is a whirlwind tour of standard database operations using LINQ to SQL. I hope I kept the examples simple enough to allow you to focus on the basic steps necessary to perform inserts, queries, updates, and deletes to the database. I also pointed out the ways that LINQ to SQL queries differ from LINQ to Objects queries.

Bear in mind that any LINQ to SQL code that changes the database should detect and resolve concurrency conflicts. However, for the sake of clarity, none of the examples in this chapter did so. I will cover concurrency conflicts thoroughly in Chapter 17 though, so don't be too disappointed.

In addition to understanding how to perform these basic operations on entity objects, it is also important to understand ...

Get Pro LINQ: Language Integrated Query in C# 2008 now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.