-->
These old forums are deprecated now and set to read-only. We are waiting for you on our new forums!
More modern, Discourse-based and with GitHub/Google/Twitter authentication built-in.

All times are UTC - 5 hours [ DST ]



Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 1 post ] 
Author Message
 Post subject: Composite PK (int, int IDENTITY) and DELETE by SET deleted=1
PostPosted: Fri May 25, 2007 6:51 am 
Newbie

Joined: Fri May 25, 2007 5:51 am
Posts: 1
Hello users,

before diving into studing details I need to check that NHibernate can handle my scenario. My (given) database schema has two specifities:

1) primary and foreign keys, EUIDs, are composites consisting from smallint and int IDENTITY. The smallint part is database id and it guarantees that whole EUID is unique over several replicated databases, clients know this one and mentions it explicitly in all INSERTs. After insert client using SCOPE_IDENTITY() retrives database server assigned int part. Most FKs do not allow NULLs.

2) there is no record ever dropped from database (excluding archiving service) but instead all 'deleted' records are marked by setting [deleted] bit field. Ideally Delete() method should toggle this flag and Find(), List() methods exclude objects for [deleted] records.

Last but not least data model is quite big, >600 tables, crashing most generators or compiler while compiling it, ... have not checked Hibernate failure equivalent, yet :-).

Are above specifities mappable and long term manageable by NHibernate?

Thank you
Cc.


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 1 post ] 

All times are UTC - 5 hours [ DST ]


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
© Copyright 2014, Red Hat Inc. All rights reserved. JBoss and Hibernate are registered trademarks and servicemarks of Red Hat, Inc.