LP on .NET

September 7, 2007

LINQ is Fantastic!

Filed under: .NET,LINQ,Orcas,technology — Larry Parker @ 2:15 am

I finally got the opportunity to use LINQ in a real project.  Up until a couple of days ago it was always a quick prototype here, install the latest CTP there, read a blog about LINQ, etc.  But there’s nothing like diving in and giving it your best shot on a data-intensive ETL app that would otherwise force you to hand-code a ton of opaque SQL strings using ADO.NET.

For the past two days, I have been sailing along and the code almost seems to be writing itself.  Well not really, but I’m almost done with my app and I have not had to write a single SQL query, and not one INSERT or UPDATE statement.

It was especially nice to see that the SQL generated by LINQ for a moderately complex query was exactly what I expected.  I was a bit concerned that the SQL would be convoluted and unnecessarily use temp tables, but after seeing what got generated I’m getting more confident that I won’t need to worry about it too much.

Perhaps the days of writing explicit SQL will become a thing of the past for me, much like writing assembler code was twenty years ago when I moved to a compiled language and no longer had to worry about the machine code behind the scenes.

Anyway, I hope to post more about LINQ as I continue to get better at it, but my initial test-drive has been extremely positive.  Thank you Microsoft!

Advertisements

1 Comment »

  1. I didn’t have the opportunity to try LINQ yet, but it seems very interesting. If you decide to post on this technology, I will be one of the regular readers ..

    Comment by Stefano — May 26, 2008 @ 8:39 pm | Reply


RSS feed for comments on this post. TrackBack URI

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

Blog at WordPress.com.

%d bloggers like this: