-->
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: How to get the database / table meta data?
PostPosted: Wed Dec 24, 2008 12:28 pm 
Newbie

Joined: Wed Dec 24, 2008 12:15 pm
Posts: 1
I am trying to figure out how to achieve the following from inside java code for one of our usage scenario: (we use using Spring / Hibernate 3.0)

1. Get the database / table information which contains the foreigh key and unique index constraint definition.

2. For each table foreign key / unique key fields obtained from step 1, what's the corresponding java field name / java data type programmatically. (Those are defined in the hibernate mapping file and I need to access those based on the database field information from step 1).

The apache DDLUtil package will give the foreign key, unique key index for each table in the whole database, but it does not know how each database field are mapped to the hibernate java object.

Any help will be greatly appreciated,

Thanks,

Mark


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.