-->
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.  [ 2 posts ] 
Author Message
 Post subject: Per-user mapping in hibernate?
PostPosted: Mon Sep 13, 2004 2:28 am 
Newbie

Joined: Mon Sep 13, 2004 2:14 am
Posts: 1
Hello,

I am new to hibernate and I would like to use it in the following scenario:

My system currently has tables which have some fix columns.
E.g. the table t10 has columns t10surname, t10forename, ...

For some user groups, the tables also have extension fields
(t10text00, t10text01, ....)

The columns are accessed via "field ids". The problem is that extension
fields can have different mappings per user group.
E.g. field id 10005 can be mapped to t10text00 for user group A and
to t10text01 for user group B.


Can hybernate be used in such a scenario?


Thank You and kind regards,

Hans

P.S.:
I know, this kind of mapping is - erm... - suboptimal. But unfortunately I cannot
change the design.


Top
 Profile  
 
 Post subject:
PostPosted: Mon Sep 13, 2004 9:38 am 
Beginner
Beginner

Joined: Mon May 03, 2004 1:25 pm
Posts: 31
I believe the schema allows for multiple session factory definitions that can be named in the configuration xml. You could include different mappings in different named session factories by user group.

I've never tried it, but it seems like it might work.


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

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.