Pro LINQ: Language Integrated Query in C# 2008


LINQ is the project name for a set of extensions to the .NET Framework that provide a generic approach to querying data from different data sources. LINQ will premier in Visual Studio 2008, and will become the next must–have skill for .NET developers. For more information about LINQ, you can check out the author’s portal at

Pro LINQ: Language Integrated Query in C# 2008 is all about code.

Literally, this book starts with code ...

See more details below
Paperback (1st ed. 2008. Corr. 4th printing 2008)
$33.40 price
(Save 25%)$44.99 List Price
Other sellers (Paperback)
  • All (36) from $1.99   
  • New (13) from $3.29   
  • Used (23) from $1.99   
Sending request ...


LINQ is the project name for a set of extensions to the .NET Framework that provide a generic approach to querying data from different data sources. LINQ will premier in Visual Studio 2008, and will become the next must–have skill for .NET developers. For more information about LINQ, you can check out the author’s portal at

Pro LINQ: Language Integrated Query in C# 2008 is all about code.

Literally, this book starts with code and ends with code. In most books, the author shows the simplest example demonstrating how to use a method, but they so rarely show how to use the more complex prototypes. Pro LINQ: Language Integrated Query in C# 2008 is different. Demonstrating the overwhelming majority of LINQ operators and protoypes, it is a veritable treasury of LINQ examples.

Rather than obscure the relevant LINQ principles in code examples by focusing on a demonstration application you have no interest in writing, Pro LINQ: Language Integrated Query in C# 2008 cuts right to the chase of each LINQ operator, method, or class. However, where complexity is necessary to truly demonstrate an issue, the examples are right there in the thick of it. For example, code samples demonstrating how to handle concurrency conflicts actually create concurrency conflicts so you can step through the code and see them unfold.

Most books tell you about the simple stuff, while few books warn you of the pitfalls. Where Pro LINQ: Language Integrated Query in C# 2008 returns your investment is in the hours, and sometimes days, spent by the author determining why something may not work as expected. Sometimes this results in an innocent looking paragraph that may take you a minute to read and understand, but took days to research and explain.

Face it, most technical books while informative, are dull. LINQ need not be dull. Written with a sense of humor, Pro LINQ: Language Integrated Query in C# 2008 will attempt to entertain you on your journey through the wonderland of LINQ and C# 2008.

What you’ll learn

  • How to leverage all the LINQ-relevant C# 2008 language features including extension methods, lambda expressions, anonymous data types, and partial methods.
  • How to use LINQ to Objects to query in–memory data collections such as arrays, ArrayLists, and Lists to retrieve the data you want.
  • Why some queries are deferred, how a deferred query can bite you, and how you can make deferred queries work for you.
  • How to use LINQ to XML to revolutionize your creation, manipulation, and searching of XML data.
  • How to query DataSets with LINQ to DataSet so you can co–exist with legacy code and use LINQ to query databases other than SQL Server.
  • How to query Databases with LINQ to SQL, write your own entity classes, and understand how to handle concurrency conflicts.

Who this book is for

This book is written for the proficient C# developer, but you do not need to be up on all the latest C# features to understand the material.

Read More Show Less

Product Details

  • ISBN-13: 9781590597897
  • Publisher: Apress
  • Publication date: 11/28/2007
  • Series: Expert's Voice In . Net Series
  • Edition description: 1st ed. 2008. Corr. 4th printing 2008
  • Edition number: 1
  • Pages: 600
  • Product dimensions: 6.96 (w) x 10.88 (h) x 1.22 (d)

Meet the Author

Joseph C. Rattz, Jr., unknowingly began his career in software development in 1990 when a friend asked him for assistance writing an ANSI text editor named ANSI Master for the Commodore Amiga. A hangman game (the Gallows) soon followed. From these compiled BASIC programs, he moved on to programming in C for more speed and power. Joe then developed applications that were sold to JumpDisk, an Amiga disk magazine, as well as Amiga World magazine. Due to developing in a small town on a fairly isolated platform, Joe learned all the wrong ways to write code. It was while trying to upgrade his poorly written applications that he gained respect for the importance of easily maintainable code. It was love at first sight when Joe spotted a source-level debugger in use for the first time.

Two years later, Joe obtained his first software development opportunity at Policy Management Systems Corporation as an entry level programmer developing a client/server insurance application for OS/2 and Presentation Manager. Through the years, he added C++, Unix, Java, ASP, ASP.NET, C#, HTML, DHTML, and XML to his skill set, while developing applications for SCT, DocuCorp, IBM, and the Atlanta Committee for the Olympic Games, CheckFree, NCR, EDS, Delta Technology, Radiant Systems, and the Genuine Parts Company. Joe enjoys the creative aspects of user interface design, and he appreciates the discipline necessary for server-side development. But, given his druthers, his favorite development pastime is debugging code.

Joe can be found working for the Genuine Parts Company the parent company of NAPA in the Automotive Parts Group Information Systems department, where he works on his baby, the storefront web site. This site for NAPA provides the stores a view into their accounts and data on a network of AS/400s.

Read More Show Less

Customer Reviews

Be the first to write a review
( 0 )
Rating Distribution

5 Star


4 Star


3 Star


2 Star


1 Star


Your Rating:

Your Name: Create a Pen Name or

Barnes & Review Rules

Our reader reviews allow you to share your comments on titles you liked, or didn't, with others. By submitting an online review, you are representing to Barnes & that all information contained in your review is original and accurate in all respects, and that the submission of such content by you and the posting of such content by Barnes & does not and will not violate the rights of any third party. Please follow the rules below to help ensure that your review can be posted.

Reviews by Our Customers Under the Age of 13

We highly value and respect everyone's opinion concerning the titles we offer. However, we cannot allow persons under the age of 13 to have accounts at or to post customer reviews. Please see our Terms of Use for more details.

What to exclude from your review:

Please do not write about reviews, commentary, or information posted on the product page. If you see any errors in the information on the product page, please send us an email.

Reviews should not contain any of the following:

  • - HTML tags, profanity, obscenities, vulgarities, or comments that defame anyone
  • - Time-sensitive information such as tour dates, signings, lectures, etc.
  • - Single-word reviews. Other people will read your review to discover why you liked or didn't like the title. Be descriptive.
  • - Comments focusing on the author or that may ruin the ending for others
  • - Phone numbers, addresses, URLs
  • - Pricing and availability information or alternative ordering information
  • - Advertisements or commercial solicitation


  • - By submitting a review, you grant to Barnes & and its sublicensees the royalty-free, perpetual, irrevocable right and license to use the review in accordance with the Barnes & Terms of Use.
  • - Barnes & reserves the right not to post any review -- particularly those that do not follow the terms and conditions of these Rules. Barnes & also reserves the right to remove any review at any time without notice.
  • - See Terms of Use for other conditions and disclaimers.
Search for Products You'd Like to Recommend

Recommend other products that relate to your review. Just search for them below and share!

Create a Pen Name

Your Pen Name is your unique identity on It will appear on the reviews you write and other website activities. Your Pen Name cannot be edited, changed or deleted once submitted.

Your Pen Name can be any combination of alphanumeric characters (plus - and _), and must be at least two characters long.

Continue Anonymously
Sort by: Showing all of 7 Customer Reviews
  • Anonymous

    Posted February 24, 2008

    Professional book about dynamic data in LINQ!

    When I get first book about LINQ technology I think this is very hard technology, but when I read this Pro LINQ in C# 2008 vademecum I change my opinion about LINQ, and I started exploration this wonderful technique. After I finished read my book from Apress I can create my first applications where I used LINQ methods and ideas to delivery dynamic data from different data sources. Every day I read some pages in this very useful and innovative book. I think this is the best source professional information and samples how developers can working with this newest technology. LINQ is powerful but If You think about creating advance application with this, You must learn about You can use features, extensions in LINQ, because some elements is very different from standard technique access to dynamic data sources. Learning with this book is simple, because you can found code, code, and again code with professional comments. Where You read book, in this same moment You can create first applications, where You can demonstrating how to use a methods, and suggest from authors. Of course If you think about learn LINQ with this book You must programming in C#, but You don¿t must be very advance, because all required theory and programming methods have a long comments. Additional, in most books author tell us how we can building specific application in next steps, but don¿t inform us how we can rebuild our apps if something may not work as expected. In Pro LINQ You find every this information. In book you find this information: ¿ How to used all new LINQ features including extension methods, lambda expressions, anonymous data types, and partial methods, ¿ how working in LINQ with XML data, ¿ how to query databases with LINQ to SQL and DataSet with LINQ to DataSet, ¿ and many new information. Summary, Joseph C. Rattz, Jr. write for Apress very professional book, and everyone professional developers who¿s think create apps with LINQ must have this book in desk, because this book can be primary source for information and samples about delivery dynamic data from different data sources.

    Was this review helpful? Yes  No   Report this review
  • Anonymous

    Posted February 1, 2008

    A well structured book and one to buy

    LINQ is latest interesting tool to come from Microsoft, along with Silverlight, WPF and the Ajax toolkit. One of difficulties about these new technologies is that there is not enough documentation readily available. This book is the first one that has really captured my attention, maybe because it's the first one on the subject. Apress books are always a great buy, however in this instance, I reviewed the eBook version, which I have to say is not the easiest to navigate. I might be a cutting edge developer but I am also an old fashion type of guy, I like the feel and smell of new books! Anyway back to the subject, LINQ. I think we can all say we are newbies on the subject except for those who are familiar with ORM 'Object Relation Mapping' technology. LINQ implementation is quite different than the other ORM tools and can be surprising in some ways sometimes for beginners. The author here has taken the broad option of covering LINQ for both beginners and professionals. It something I like a lot because it avoids the need for two books on the same subject, which often can mean you never quite find the right piece of code you are looking for. Kudos to the author who admits that this is his first book I think he should continue writing. I would have no problem recommending another book by the same author . The introduction is a well written exercise, where the writer gets the reader's attention using some clever basic 'hello' messages coded with LINQ before he delves into a deeper understanding of the language. The style is straightforward, taking an honest approach. You won't find any pompous statements in the book saying something like 'I know what I am talking about, I was born with LINQ!', but instead you find a more frank admission that the author has also learned by writing on the subject himself. I am looking forward now to a VB version of the book, because this is the only negative comment I can make. It would have been easy to write the examples in VB and C# in the same book. I can code in both, but I know you have subtle differences. LINQ is not only for database gurus, and I like the fact that in the book the LINQ to SQL has been pushed further down the content list. What is also good is that because the book is well structured you can jump directly to any section. I would have added more diagrams and graphics to the text to lighten what is a heavy read. Another little thing but useful for the beginners would have been to have some explanations on using the LINQ designer class in Visual Studio 2008, which is quite absent as far as I could see. Now I do hope that my review will encourage you to buy this book because not only is it the first one on the subject, but because it covers almost everything you need to know on the subject.

    Was this review helpful? Yes  No   Report this review
  • Anonymous

    Posted January 19, 2008

    LINQ - is already here!

    In the last few months I started to learn one of the great frameworks from Microsoft named LINQ. In order to get a better understand about the LINQ framework I read a lot from the official Microsoft documentation. I even shared people in my thoughts about the LINQ project 'I focused on LINQ to SQL with its pervious name D-LINQ', in my blog. After a while I took a time to read the 'Pro LINQ' book. This book exposes me to some fundamentals in the LINQ world which I wasn't familiar with, and helped me to improve my knowledge in the LINQ world. The LINQ framework is based on some new features from the new C# 3.0. Therefore this book brings a short briefing about these features, each one of them accompanied by good demonstration. Every chapter in this book is 'almost' standing alone. My favorite section in this book was the LINQ to SQL. It's the most powerful and interesting part in the LINQ Framework. The book starts this section with a small chapter that helps the readers to understand the basic terminology about all the LINQ to SQL components. The book contains all the detail about verity options to work with the LINQ to SQL in the real work. Furthermore, the book compares some of these methods and gives us the ability to choose the appropriate solutions based of your needs 'like: Projecting into Entity Classes vs. Nonentity Classes, Using the SqlMetal command line or the Object Relational Designer, XML Mapping File Vs. DBML Intermediate File and etc'. The book contains a lot of tips that really can help during the daily work. I'll mention the top 5 tips that can help you to implement LINQ to SQL in your application: ¿How to support the legacy code. ¿How to use the Data Context Logger. ¿Take Advantage of Deferred Queries ¿Consider Using Partial Classes or Mapping Files ¿Consider Using Partial Methods. While the book shows the ability of the auto generated sophisticated code, it gives good guidelines of how to write all this code in your own hands and a set of rules about the issues that you should be aware when you implement it by yourself. I really re commend this book for all people that want to learn about LINQ from introduction to professional level.

    Was this review helpful? Yes  No   Report this review
  • Anonymous

    Posted November 23, 2007

    A reviewer

    This year, at TechEd 2007 EMEA, LINQ turned out to be THE HOT topic of the event. Because of high interest many LINQ-related sessions had to be repeated. So I was happily surprised to find that Apress already had a LINQ-book in the PRO-series, which assures me to provide me no-nonsense technical content I need as a professional software developer. And was I right... The book starts with CODE 'first line of chapter 1' and ends with CODE 'last line in chapter 18', what can a developer want more? In a fluent prose, the author covers all variations of LINQ LINQ to Objects, XML, DataSet, SQL and Entities. At the right place new C# 3.0 features like extension methods, anonymous types, lamba expressions, etc come into play, not without showing their use and value for the LINQ-topic being covered. For my day-to-day programming, I do a lot of XML-processing, so I mostly appreciated part 3 with 4 chapters dedicated to LINQ to XML. It showed me how to migrate my existing code, using a variation of XPATH, XSLT and .NET's Xml-Readers/Writers, Navigators and Iterators, etc. to this powerful uniform API. After the last page, you don't end up with just another book for on the shelf, this is one to keep close at hand 'that's where mine is'. Besides teaching a new .NET-language topic, it offers clear samples, shows 'hidden' pitfalls and gives lots of practical tips. As said it's a PRO-book, meaning some mature level of programming skills is preferred.

    Was this review helpful? Yes  No   Report this review
  • Anonymous

    Posted January 8, 2008

    LINQ: More than just an ORM

    When I first heard someone describe LINQ, I thought 'Oh, another ORM... that doesn't sound very exciting'. Upon further research I discovered that LINQ is actually quite a bit more than just 'another ORM', in fact, I would say it is one of the more interesting things from Microsoft lately. The book Pro LINQ does a very good job of covering this new technology, and it does so in a way that you would expect for a 'Professional' level book. For example, I found it immediately appealing that Chapter 1 starts with a code example before ever getting to any regular text. The rest of the book follows suit. There are plenty of explanations, but sometimes seeing the code & result provides the clearest view. The author does a good job of explaining the technology in detail, why it is useful, and very practical tips on how to make the most of it. The book covers using LINQ to query Objects, XML, DataSets and finally SQL. I have used the book as an introduction to the topic, and for that it has done an excellent job. It appears that the book is comprehensive enough to also serve as a working reference book, but I have not personally had the chance to use it as such yet.

    Was this review helpful? Yes  No   Report this review
  • Anonymous

    Posted December 4, 2007

    Book Review - Pro LINQ: Language Integrated Query in C# 2008

    Recently I've started to read a book about LINQ. I must say, LINQ language some how manage to amaze me each time i starting a new topic, it already changed the way I code. I consider LINQ to be a 'Must Know' language for every developer in every day coding. This book is very light to understanding, and contains allot of good code examples with allot of explanations in it, step by step. Later in the book, the language starts to be more complex and less understandable, because of some complex code samples. Nonetheless, if you determine to understand the code, and read it couple of time again, finally you will understand the complex code. It covers all the LINQ related topics: LINQ to Objects LINQ to XML LINQ to DataSet LINQ to SQL LINQ to Entities You will also find some lambada expression with a good explanation about what the hack are they doing and way. I must say, that I having allots of fun learning from this book, because the ease of the syntax and the language by the author Jr. C. Rattz, this book is speaking my language so i found it very educating. I really recommend this book for developers how already start messing with LINQ and not for beginners developers.

    Was this review helpful? Yes  No   Report this review
  • Anonymous

    Posted December 29, 2008

    No text was provided for this review.

Sort by: Showing all of 7 Customer Reviews

If you find inappropriate content, please report it to Barnes & Noble
Why is this product inappropriate?
Comments (optional)