Home > Articles > Programming > Windows Programming

  • Print
  • + Share This
From the author of


When I first experienced LINQ, it seemed atrocious. With a little exploration and understanding, however, it seems elegant and straightforward. Switch the from and select clauses from their order in SQL, and LINQ is very similar to SQL.

Notice that the bulk of the work is simply mapping a table to a class with attributes. LINQ to SQL does almost everything else. Of course, if you want to be really productive, you can use the SQLMETAL command-line utility to generate the mapped entity classes for you, but that's another article.

Paul Kimmel is an architect for EDS and the cofounder of the Greater Lansing Area .NET Users Group (glugnet.org, Flint and East Lansing). Look for his new book, LINQ Unleashed: for C# (Sams, summer 2008, ISBN 978-0672329838). If you have a programming question, you can contact Paul at pkimmel@softconcepts.com.

  • + Share This
  • 🔖 Save To Your Account