Chapter 21. Introduction to LINQ

What Is LINQ?

LINQ is a new feature of C# and Visual Basic .NET that integrates into these languages the ability to query data.

In a relational database system, data is organized into nicely normalized tables, and accessed with a very simple but powerful query language—SQL. SQL can work with any set of data in a database because the data is organized into tables, following strict rules.

In a program, as opposed to a database, however, data is stored in class objects or structs that are all vastly different. As a result, there has been no general query language for retrieving data from data structures. The method of retrieving data from objects has always been custom-designed as part of the program. With the introduction ...

Get Illustrated 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.