Click here to Skip to main content
15,890,185 members
Home / Discussions / Design and Architecture
   

Design and Architecture

 
NewsRe: Information Relation Modeling Pin
Daniel Lieberwirth (BrainInBlack)7-Mar-15 4:34
professionalDaniel Lieberwirth (BrainInBlack)7-Mar-15 4:34 
QuestionPrimaryKey-Generation-Strategy in n-Tier Pin
manchanx25-Feb-15 7:21
professionalmanchanx25-Feb-15 7:21 
AnswerRe: PrimaryKey-Generation-Strategy in n-Tier Pin
Wendelius25-Feb-15 7:57
mentorWendelius25-Feb-15 7:57 
GeneralRe: PrimaryKey-Generation-Strategy in n-Tier Pin
manchanx25-Feb-15 21:24
professionalmanchanx25-Feb-15 21:24 
GeneralRe: PrimaryKey-Generation-Strategy in n-Tier Pin
jschell26-Feb-15 9:45
jschell26-Feb-15 9:45 
GeneralRe: PrimaryKey-Generation-Strategy in n-Tier Pin
manchanx26-Feb-15 20:20
professionalmanchanx26-Feb-15 20:20 
GeneralRe: PrimaryKey-Generation-Strategy in n-Tier Pin
jschell27-Feb-15 10:19
jschell27-Feb-15 10:19 
GeneralRe: PrimaryKey-Generation-Strategy in n-Tier Pin
manchanx27-Feb-15 20:00
professionalmanchanx27-Feb-15 20:00 
jschell wrote:
One is more than none.
Batching it solves that problem but it doesn't explain why the client needs to provide the ids.
I don't think I deserve your impatience with me because you could have found the explanation in another post of me in this thread:

[..] the main point why I need at least some kind of key is that I implement object-references "virtually" (don't know if there's a better term for it): Entities don't hold a direct reference to other entities but a key and on property access the key gets resolved into an object reference - that way I can easily implement lazy/implicit loading and cache expiration.

To put it into picture: I'm developing a custom ORM, mainly because of one requirement that disqualifies existing ORMs: My users need to be able to extend the model with custom tables and fields (which of course need to be "non-intrusive" on the business-logic by being nullable/optional). The first version of the application will only include desktop clients and those will be rich clients where the part of the ORM that does the record-entity mapping resides in the client. So probably you could say that I split up the DAL into tiers. This will probably clear up the following:
jschell wrote:
Again I would not write a DAL nor a database (relational) that relied solely on a client for validity.
The DAL I've been talking about is essentially that part of a DAL which you're thinking about that does the final step of saving the raw records. Any validation you would do in a DAL happens here in the first layer of the client.

So I need Id's/keys in the client because they're required to resolve references.
GeneralRe: PrimaryKey-Generation-Strategy in n-Tier Pin
jschell4-Mar-15 9:00
jschell4-Mar-15 9:00 
GeneralRe: PrimaryKey-Generation-Strategy in n-Tier Pin
manchanx5-Mar-15 3:13
professionalmanchanx5-Mar-15 3:13 
GeneralRe: PrimaryKey-Generation-Strategy in n-Tier Pin
jschell6-Mar-15 10:52
jschell6-Mar-15 10:52 
AnswerRe: PrimaryKey-Generation-Strategy in n-Tier Pin
Mycroft Holmes25-Feb-15 13:21
professionalMycroft Holmes25-Feb-15 13:21 
GeneralRe: PrimaryKey-Generation-Strategy in n-Tier Pin
manchanx25-Feb-15 21:25
professionalmanchanx25-Feb-15 21:25 
GeneralRe: PrimaryKey-Generation-Strategy in n-Tier Pin
Mycroft Holmes25-Feb-15 21:49
professionalMycroft Holmes25-Feb-15 21:49 
GeneralRe: PrimaryKey-Generation-Strategy in n-Tier Pin
manchanx25-Feb-15 22:18
professionalmanchanx25-Feb-15 22:18 
GeneralRe: PrimaryKey-Generation-Strategy in n-Tier Pin
Pete O'Hanlon25-Feb-15 23:07
mvePete O'Hanlon25-Feb-15 23:07 
GeneralRe: PrimaryKey-Generation-Strategy in n-Tier Pin
manchanx26-Feb-15 0:06
professionalmanchanx26-Feb-15 0:06 
GeneralRe: PrimaryKey-Generation-Strategy in n-Tier Pin
Pete O'Hanlon26-Feb-15 0:17
mvePete O'Hanlon26-Feb-15 0:17 
GeneralRe: PrimaryKey-Generation-Strategy in n-Tier Pin
manchanx26-Feb-15 1:04
professionalmanchanx26-Feb-15 1:04 
GeneralRe: PrimaryKey-Generation-Strategy in n-Tier Pin
Pete O'Hanlon26-Feb-15 1:10
mvePete O'Hanlon26-Feb-15 1:10 
GeneralRe: PrimaryKey-Generation-Strategy in n-Tier Pin
manchanx26-Feb-15 1:23
professionalmanchanx26-Feb-15 1:23 
GeneralRe: PrimaryKey-Generation-Strategy in n-Tier Pin
Pete O'Hanlon26-Feb-15 2:06
mvePete O'Hanlon26-Feb-15 2:06 
GeneralRe: PrimaryKey-Generation-Strategy in n-Tier Pin
manchanx26-Feb-15 2:32
professionalmanchanx26-Feb-15 2:32 
GeneralRe: PrimaryKey-Generation-Strategy in n-Tier Pin
Pete O'Hanlon26-Feb-15 4:25
mvePete O'Hanlon26-Feb-15 4:25 
GeneralRe: PrimaryKey-Generation-Strategy in n-Tier Pin
manchanx26-Feb-15 4:56
professionalmanchanx26-Feb-15 4:56 

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.