Click here to Skip to main content
15,910,123 members
Home / Discussions / Design and Architecture
   

Design and Architecture

 
GeneralRe: Help! NHibernate data saving problem. Pin
Mark Churchill30-Jan-08 2:05
Mark Churchill30-Jan-08 2:05 
GeneralRe: Help! NHibernate data saving problem. Pin
Harry Sun30-Jan-08 16:59
Harry Sun30-Jan-08 16:59 
Generalshape locations Pin
netJP12L29-Jan-08 6:50
netJP12L29-Jan-08 6:50 
GeneralUnrelated data layer question. Pin
MatthewSmith27-Jan-08 9:35
MatthewSmith27-Jan-08 9:35 
GeneralRe: Unrelated data layer question. Pin
led mike28-Jan-08 6:13
led mike28-Jan-08 6:13 
GeneralRe: Unrelated data layer question. Pin
MatthewSmith28-Jan-08 7:34
MatthewSmith28-Jan-08 7:34 
GeneralRe: Unrelated data layer question. Pin
led mike28-Jan-08 8:34
led mike28-Jan-08 8:34 
GeneralRe: Unrelated data layer question. Pin
Mark Churchill28-Jan-08 20:11
Mark Churchill28-Jan-08 20:11 
The common way people end up writing their DAL seems to be creating a procedural CRUD interface, which hits stored procedures in the DB ("for security" / "for performance"). This is generally done because people aren't leveraging the metadata features of the language.

Also people like to use the Enterprise Data Access Block. So much so that they use it for general data access - when its really just a database abstraction kit - when they have no plans to ever switch database vendors. That ends up locking them out of a whole heap of cool tools :P

In .Net at least, its possible to make a generic persistance layer that can operate on any business object which is correctly tagged up with persistance attributes. With a smattering of generics you can have a single persistence layer that isn't aware of your business objects.

The way we do this is using reflection to read attributes that map the object model to the database schema. Reflection does have a small performance overhead - but you can make up for that by flexible queries - for example joining on referenced records in one round-trip. It also lets you provide generic FindByX routines, etc.

So, yes, it is possible - and its a lot better than having to keep a whole bunch of structures that are only used for passing data between tiers maintained Wink | ;)


GeneralRe: Unrelated data layer question. Pin
dojohansen11-Feb-08 8:10
dojohansen11-Feb-08 8:10 
GeneralRe: Unrelated data layer question. Pin
dojohansen11-Feb-08 8:04
dojohansen11-Feb-08 8:04 
GeneralDAL Design Question Pin
Waleed Eissa24-Jan-08 2:42
Waleed Eissa24-Jan-08 2:42 
GeneralRe: DAL Design Question Pin
Mark Churchill25-Jan-08 4:24
Mark Churchill25-Jan-08 4:24 
GeneralRe: DAL Design Question Pin
led mike25-Jan-08 4:40
led mike25-Jan-08 4:40 
GeneralRe: DAL Design Question Pin
Mark Churchill25-Jan-08 4:55
Mark Churchill25-Jan-08 4:55 
GeneralRe: DAL Design Question Pin
Waleed Eissa27-Jan-08 3:16
Waleed Eissa27-Jan-08 3:16 
GeneralRe: DAL Design Question Pin
Mark Churchill27-Jan-08 5:19
Mark Churchill27-Jan-08 5:19 
GeneralRe: DAL Design Question Pin
Waleed Eissa1-Feb-08 18:58
Waleed Eissa1-Feb-08 18:58 
GeneralRe: DAL Design Question Pin
Ashfield30-Jan-08 4:24
Ashfield30-Jan-08 4:24 
QuestionBeta Testing? Develop Tech? Pin
Chrispie12323-Jan-08 19:00
Chrispie12323-Jan-08 19:00 
AnswerRe: Beta Testing? Develop Tech? Pin
Paul Conrad25-Jan-08 15:56
professionalPaul Conrad25-Jan-08 15:56 
GeneralVisual Studio 2005 collaboration Pin
Mike Nelson22-Jan-08 1:47
Mike Nelson22-Jan-08 1:47 
GeneralRe: Visual Studio 2005 collaboration Pin
led mike22-Jan-08 4:59
led mike22-Jan-08 4:59 
GeneralRe: Visual Studio 2005 collaboration Pin
Mike Nelson22-Jan-08 7:49
Mike Nelson22-Jan-08 7:49 
GeneralRe: Visual Studio 2005 collaboration Pin
led mike22-Jan-08 7:58
led mike22-Jan-08 7:58 
GeneralRe: Visual Studio 2005 collaboration Pin
Mike Nelson28-Jan-08 2:55
Mike Nelson28-Jan-08 2:55 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.