LINQPad is a fantastic freeware application that lets you interactively query SQL databases using LINQ (Language Integrated Query).
In this brave new world where LINQ will become more popular an will be broadly adopted by the .NET community it will become very important to become fluent with your use of LINQ. One way to accomplish this is by replacing your use of SQL Management Studio for interactively querying SQL databases with LINQPad.
According the the LINQPad website you can "Kiss goodbye to SQL Management Studio !". Does LINQPad replace SQL Management Studio for interactively querying SQL databases?
Until I found Matt Perdeck's LINQ to CSV library an easy to use library to read and write CSV and tab delimited files with LINQ queries, I would have said LINQPad is not ready.
In my opinion there are only two reasons not to use LINQPad and both problems are solved by LINQtoCSV.
- LINQPad lacks the ability to export query results to a csv file.
- LINQPad's output is limited to 1000 Records.\
Here's how to configure LINQPad to use LINQtoCSV.
Step 1: Download LINQtoCSV and copy to the folder of you choice.
Step 2: Add "LINQtoCSV.dll" Assembly Reference to Tab called "Additional References" (Query >> Advanced Properties) or (F4)

Step 3: Add "LINQtoCSV" Namespace Reference to Tab called "Additional Namespace Imports"
Step 4: Press the Set as default for new queries button and close the window.
Step 5: Set Query Type to C# Statement(s)
Step 6: Add standard LINQtoCSV code to your Query.
| //Initialize LINQtoCSV CsvFileDescription outputFileDescription = new CsvFileDescription { SeparatorChar = ',', FirstLineHasColumnNames = true, }; CsvContext cc = new CsvContext(); //Your LINQ Statement //Dump Results of LINQ Statement //Write LINQtoCSV File |
About This Website
Welcome to FantasticFreeware.com's .NET Blog . This Blog is dedicated to Fantastic .NET Framework Freeware Applications and Technology. The .NET technologies that you will find here are C#, VB.NET, ASP.NET, .NET 2.0, 3.0, & 3.5 Frameworks, LINQ, WCF, WPF, Silverlight just to name a few.
Subscribe to the FantasticFreeware.com .Net Blog RSS feed here:
FantasticFreeware - is my personal Library of every freeware program that I have found useful.
I have cataloged over 2700+ of only the best hand picked freeware programs since 2003. To make the list it must be a true freeware application. No demos, trial, shareware, and etc. I continually add to the collection and add about half dozen new freeware applications every week. The current size of my personal catalog is 50GB and growing. The programs a categorized by major groupings. (Disk, Internet, Security, Development, and etc)














0 Responses to “LinqPad’s Missing Linq - LINQtoCSV”