Introduction

LINQ is a programming model which makes use of a set of programming language enhancements to allow programmers to easily query any data source. Even more, the query can perform transformations on the results and return data formatted to suit the particular requirements of the application. The programming language features are fully supported in Visual Studio and you can take advantage of code completion, type safety and compile time checking.

The underlying  language features that enable LINQ are dealt with separately. These are:

  • Automatic Properties
  • Initialisers
  • Extension Methods
  • Lambda Expressions
  • Query Syntax
  • Anonymous Types

LINQ support has been built into domain specific libraries which allow it to be used with data sources such as databases, and XML, as well as Objects.

This introductory tutorial will cover the programming concepts which are fundamental to LINQ and move onto an introductory treatment of LINQ to SQL.

This mini-tutorial is based on the structure of a set of blog entries by Scott Guthrie. I have simplified the treatment, and use less complex examples. If you want to know more you should make Scottgu's blog your first stop off point.

Valid XHTML 1.0! | Valid CSS! | WCAG Approved AA
Page design by: John P Scott - Hosting with: Netcetera