tags:

views:

854

answers:

3

A typical stored procedure in our system accepts around 20 or so parameters. There's no chance of refactoring these stored procedures either. I've basically resorted to writing my own code generator that wraps these SP's into (database provider agnostic) "Command" objects, with their public properties corresponding to the SP parameters. It works, but I'd prefer a 3rd party tried and tested solution.

Can anyone recommend anything? I haven't found one that supports OleDB and stored procedures.

Edit: I need OleDb connectivity because of SQL 6.5 (believe it or not). ADO.NET cannot connect to SQL 6.5. Also, this is a .NET 2.0 application, so LinqToSql is of no use to me.

Edit2: I've already tried nHibernate and iBatis. Neither of them suit my needs. The last time I tried nHibernate it required that the SP return a result set. That isn't the case with my SPs. Both of them also require me to manually specify the parameters.

A: 

Alternatives:

  1. LINQ to SQL
  2. ADO.NET Entity Framework
  3. NHibernate
  4. Your choice )
dimarzionist
A: 

From what I've heard ADO .NET Entitry framework has litle support on stored procedures... LINQ2SQL you can make it work but may require somekind of a proxy class... NHibernate and IBatis is your best bet...

RWendi
+3  A: 

I have experience with 3 ORM layers:

All three are free, support OleDb connections, and stored procedures.

Subsonic - This one was built specifically for web applications. It mimics a lot of what Ruby On Rails does. They just added migrations. Subsonic is the lightest of the three. It's a tad harder to use for Winforms, but not as hard as I though it would be. It comes with a nice UI tool to generate the code and maintain database settings. This is the only one that has support for different databases. I've used it with SQLite, SQL Server CE, and SQL Server.

CSLA.NET - This one can pretty much handle pretty much all of the new and shinny .NET technologies. I know that the author just added support for WCF, WPF, and Silverlight. This is what I use when I need very heavy lifting with enterprisey type apps. It has a lot of nice features like unlimited object undo, the ability to mark collections as read only, and the ability to move and anchor objects anywhere you want. This is the closest you will get to what JBoss does on Java.

Net Tiers - I'm not a big fan, but it will get the job done. It's lighter than CSLA, but still heavier than Subsonic.

I would to also mention NHibernate, Castle Active Record, and Microsoft Enterprise Library. I don't have much experience with these though.

hectorsosajr
Are you sure Subsonic supports OleDB?
Jonathan Webb