home

ORM for .NET

It’s not pretty, but today, I started writing my own Object Relational Mapper in .NET (C#).

After using Ruby and the Rails framework including the ORM framework that is ActiveRecord, it just seems so cludgy to write:

string strInsertCommand = "INSERT INTO [table]([col1, col2, ...)
    VALUES(@col1, @col2, ...);"
// ... and repeat ...

I know, too spoiled to write my own SQL. Well, what I’m not telling is that I’m using some Stored Procedures, which don’t really translate all that well into the ORM world. That, and my ORM is really nasty since it goes out and queries the table first for the columns, then builds INSERTS based on that. Makes me wonder how ActiveRecord really does it….

Leave a Reply

Type the word "seebq" here: