[Mono-dev] Linq, Nhibernate or subsonic ?

DB Jobs dbjobs at snafu.de
Mon Feb 25 06:43:44 EST 2008


regarding NHibernate: I've used it in a small project cooperating with 
someone accustomed to it and found it very interesting but hard to 
learn. And once you know how to use it's object model you need another 
project to find out how to configure it. So, to avoid costly beginner's 
mistakes paying an onsite consultant for a few days would be a good idea.

Regarding exposing stored procedures in DAL: we rolled our own 
(different project). Just write a .NET app that creates a method for 
every SP. The method will take the parameters the SP expects, create 
Parameter objects, call the SP and return any OUT parameters etc. For 
each SP we had one method with and another without an additional 
transaction parameter. This generator avoids a lot of manual work and 
errors, DB and code are always in sync, you get code completion, etc.

In that project we also wrote a very light wrapper around ADO.NET. It 
simply offered static methods for ExecuteScalar(), Fill(), etc. Each 
came in different flavours taking either a Command object or an SQL 
string and optionally a transaction parameter-and of course no 
Connection parameter. The main reason for writing the wrapper was to 
make sure unmanaged ressources got freed but it also provided tracing.

Writing both parts of the DAL took about a week each. They work 
flawlessly and are easy to understand and maintain. OTOH when I was 
called in the main focus was to boost code quality ASAP-your situation 
is different. Also, this solution doesn't offer caching. But unless your 
company is quite big your DB server will be able to handle the the load 


Sharique uddin Ahmed Farooqui wrote:
> Hi,
> I'm planning to build an ERP for my organisation. We will use mono as 
> primary development platform. I'm a bit confused abt what should for 
> DAL. I know little abt linq .
> What I have decided for DAL is
> 1. auto generated code must be extend able either in same class or as a 
> separate class.
> 2. It must expose all databse views, triggers, stored procedures in DAL.
> Pls help me find out the right thing.
> Thanks.
> -- 
> Sharique uddin Ahmed Farooqui
> (C++/C# Developer, IT Consultant)
> A revolution is about to begin.
> A world is about to change.
> And you and I are "the initiator".
> ------------------------------------------------------------------------
> _______________________________________________
> Mono-devel-list mailing list
> Mono-devel-list at lists.ximian.com
> http://lists.ximian.com/mailman/listinfo/mono-devel-list

More information about the Mono-devel-list mailing list