Monish Nagisetty's Space

Building connectivity on-premise, in the cloud and beyond

Active Record

A few days back, a colleague of mine showed me Castle Project’s ActiveRecord.  This neat little project is an implementation of the ActiveRecord design pattern.  It sits on top of NHibernate.  Go check it out!

My colleague and I also discussed some of the misconceptions about Object Relational Mappers.  There are people out there who believe ORM architectures generate inefficient SQL to carry out the standard CRUD tasks.  We even ventured into the whole debate of StoredProcedures vs Dynamic SQL. Which is faster? Turns out that the recent versions of MS SQL Server (2000 and 2005) has some optimizations to make both data access methods equally performant.

Most of the ORM tools meet the performance of regular stored procedures by using sp_executesql to carry out most of the SQL.  The difference is in the way SQL server caches the execution plan when using sp_executesql as opposed to exec.  See this article for more on this:


January 19, 2007 - Posted by | Database |

No comments yet.

Leave a Reply

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

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

Google+ photo

You are commenting using your Google+ 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 )

Connecting to %s

%d bloggers like this: