This plain-English guide gives you a thorough overview of LINQ, from understanding the tasks it performs to making LINQ work with both Visual Basic and Visual Studio 2005. It explains the four LINQ providers in the .NET Framework, the easiest ways to go about accessing data, and how to write more efficient applications with less code using LINQ. There’s also clear guidance on combining third-party providers with LINQ to create even more powerful apps. With this single, comprehensive guide, you’ll discover how to:
- Use one query language with all Microsoft languages
- Examine .NET language extensions and work with extension methods, partial methods, lambda expressions, and query expressions
- LINQ to DataSet operators, SQL server operations, XML API, or Active Directory
- Deal with databases — download and install the Northwind database, generate Northwind entity classes, and create the Northwind XML mapping file
- Create the partial class example, the partial method example, and the database modification example
- Use objects with LINQ
- Query databases in Visual Basic and C#
As an added bonus, you can visit the companion Web site for LINQ examples in C# and Visual Basic. With LINQ For Dummies, you’ll link up with LINQ in no time and see how you can query almost anything!
Note: CD-ROM/DVD and other supplementary materials are not included as part of eBook file.
Introduction 1
Part I: An Overview of LINQ 7
Chapter 1: Getting to Know LINQ 9
Chapter 2: Creating Simple LINQ Queries 23
Chapter 3: Considering the .NET Language Extensions 47
Chapter 4: Working with LINQ in Visual Basic .NET 69
Chapter 5: Working with LINQ in Visual Studio 2005 91
Part II: Using Standard LINQ to Technologies 105
Chapter 6: LINQ to Object 107
Chapter 7: LINQ to DataSet 133
Chapter 8: LINQ to SQL Server 157
Chapter 9: LINQ to XML 181
Part III: Extending LINQ to New Horizons 211
Chapter 10: Using LINQ with Office 2007 213
Chapter 11: Advanced LINQ to SQL Server 233
Chapter 12: LINQ to Active Directory 253
Chapter 13: Other LINQ to Strategies 271
Part IV: The Part of Tens 299
Chapter 14: Ten Ways to Improve LINQ Development 301
Chapter 15: Ten Ways to Reduce Application Support Costs 321
Chapter 16: Ten LINQ Resources 335
Index 347
So you're the inquisitive type? LINQ answers your biggest query — "Why can't I develop database and XML queries in a language I already know?" This book introduces you to LINQ and the .NET Framework technologies, so you can use LINQ to query any object, any dataset, any kind of XML, SQL Server, and more — no questions asked.
-
Connect with LINQ — understand the tasks LINQ performs, declarative programming, and how to use LINQ in the real world
-
Extend yourself — examine .NET language extensions and work with extension methods, partial methods, lambda expressions, and query expressions
-
Choose your language — work with LINQ using C# along with Visual Basic® or Visual Studio®
-
LINQ up — LINQ to DataSet operators, SQL server operations, XML API, or Active Directory®
-
Deal with databases — download and install the Northwind database, generate Northwind entity classes, and create the Northwind XML mapping file
Visit the companion Web site at www.dummies.com/go/linqfd for all the source code you need
Open the book and find:
-
How LINQ lets you create more efficient applications with less code
-
An overview of the LINQ namespaces
-
What to do with expression trees
-
The four LINQ providers in .NET Framework
-
How to use objects with LINQ
-
What LINQ can do for the Visual Studio developer
-
Techniques for getting information about your applications
-
The easiest ways to access data