Showing posts from December, 2015

Linq Database Experiment.

I've recently run an interesting experiment. I created a set of classes that make files that are readable via the TextFieldParser enumerable and in the case of delimited fields it will pull in the first record as column names. The significance of this is that I can now use Linq queries and treat them like database tables. In addition to the flexibility of the text field parser I used a stream view on a memory mapped file for access to the table files. This approach allows larger files to be handled efficiently as long as the result set isn't large. Below is an example application I wrote to test these classes. The Linq functionality combined with these classes give us similar functionality to SQL select statements on structured files. On more than one occasion I've seen developers load information into a database and handle operations there to ease development. I believe using this technique will allow developers to use similar techniques without needing a full RDBMS. In a…