Tuesday, 20 December 2011


I've never really enjoyed using SQL to query a relational database in my apps (primarily because of the object-relational impedance mismatch), I have enjoyed being able to throw all of that relational logic over to an Object to Relational Mapping (ORM) framework. At present, I'm using Microsoft's Entity Framework but I've also heard that NHibernate isn't a bad open source alternative. One thing I love about ORM framework's like Entity Framework is that they give me the ability to query my data source's using LINQ. LINQ is similar to SQL in the sense that it's a declarative way of forming a query (the syntax is also not that different from SQL). However, a LINQ query is embedded and compiled within a C# assembly.

About a year ago I came across LINQPad which is a graphical tool that lets you execute C# in a nice little sandbox-like environment. I've used LINQPad extensively to practice C#/LINQ and can't recommend it enough. There is a free and paid version. The last time I checked, the main difference between the two versions is that the paid version supports intellisense.

A  highly recommended tool for someone new to C# who just wants a quick alternative to Visual Studio for trying out a code snippet, whether LINQ-based or not.