Sign in
in
   
"It is the mark of an educated mind to be able to entertain a thought without accepting it."  -Aristotle

About Me

I am a co-founder of Notches, an early stage startup currently based in NYC. We are building a free, open reviews network that anyone can participate in and anyone can build on top of. You can find out more on our official blog.

Read more about my background.

Connect with me on...

Recent Readers

Flickr Photos

 

Warning:

This article is more than 45 days old. Given the speed at which the technology world moves, this post is probably somewhat out of date. Please keep this in mind when reading the post. If this is a tutorial, please check whether you are using the same versions mentioned in the article.

What do you think about LINQ?

Leon points out some LINQ love. Well, the article may be great, but I'm a bit more torn on the technology itself.

The computer scientist part of me finds this very cool from an implementation perspective. The combination of anonymous types, lambda expressions, method extensions and a bit of compiler magic is a really neat do all of this.

On the other hand, I'm still not sure I see the practical side of things. I cringe when I think of all the query logic that is going to be embedded in code. Actually, from this perspective my real problem is with DLINQ, not the LINQ syntax itself. That is, I really have no problem with a syntactic nicety on in-memory objects, I'm just a little more concerned when your code is so tied to an external data source.

Yes, having the query as typed objects in code is better than having the query as a string. But really isn't the goal not to have the query in there at all? This is just terrible practice for any enterprise development. There is a reason we have tiered architectures - because we want abstraction between the levels. The DataSet, while perhaps a bit heavyweight, has proven to be a great means to handle these abstractions.

Rather than integrating queries into the C# language, I would prefer something that promoted a more formal separation of code and query. We've gone through great lengths to do this with a metabase framework that externalizes the query.

Of course, the other aspect of this is that Yukon will host the CLR. LINQ in the database itself is a but more intriguing. It's about time we found a better, strongly-typed alternative to SQL.

Only published comments... Oct 07 2005, 08:49 AM by Tim

View related posts

 

Loosely Coupled // Tim Marman's Weblog said:

Microsoft has released the first CTP for ADO.NET vNext which implements their vision for an Entity Framework

September 5, 2006 10:36 AM
 

Loosely Coupled // Tim Marman's Weblog said:

Microsoft has released the first CTP for ADO.NET vNext which implements their vision for an Entity Framework

September 5, 2006 10:36 AM
 

the ‘bee log » Blog Archive » On LINQ Hesitation said:

September 14, 2006 11:02 PM