-->
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.  [ 4 posts ] 
Author Message
 Post subject: Specifying Owner ID for DB2 in Hibernate
PostPosted: Mon Nov 22, 2004 5:03 pm 
Newbie

Joined: Mon Nov 22, 2004 5:01 pm
Posts: 2
Hi,

I am trying to use Hibernate with DB2. DB2 tables have a owner id prefix.
where do you specify the owner ID?


Top
 Profile  
 
 Post subject:
PostPosted: Tue Nov 23, 2004 12:34 pm 
Newbie

Joined: Mon Nov 22, 2004 5:01 pm
Posts: 2
I prefixed the owner ID in front of the table name in .hbm.xml file in hibernate mapping. It works. Is this the only way? Iam sure there must be a better way than this.


Top
 Profile  
 
 Post subject:
PostPosted: Mon Dec 06, 2004 7:48 am 
Newbie

Joined: Mon Dec 06, 2004 4:52 am
Posts: 5
Hi,

use the following in your hibernate.properties:

## specify a default schema for unqualified tablenames
hibernate.default_schema username


Top
 Profile  
 
 Post subject:
PostPosted: Mon Dec 06, 2004 8:50 am 
Hibernate Team
Hibernate Team

Joined: Tue Aug 26, 2003 6:10 am
Posts: 8615
Location: Neuchatel, Switzerland (Danish)
this can also be specified in the hbm.xml if you uses tables from multiple schemas.

_________________
Max
Don't forget to rate


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 4 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.