• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Hibernate - Reverse Engineer - Oracle

 
Ranch Hand
Posts: 55
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hello folks,

I have got an Oracle database with no primary keys defined, just unique constraints. So when I do my reverse engineering for example in a ACCOUNT table I have the following Java model "reversed":

Account


AccountId


So, I tried to define a primary key within my reveng.xml:



But it doesn't work. I realized that the <table> tag is not been read. I can go like this:



Trying to exclude this column but I still get the two classes Account, AccountId with my VERSION column.

Anybody has got any similar problem?
One interesting thing, is that I did the same in a PostgreSQL database and it worked, I could define my primary keys, change my class name and everything... it seems to be something with Oracle.. just guessing..

Anyway, I would appreciate very much any help!
Cheers!
 
Bruno Frascino
Ranch Hand
Posts: 55
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hello,

Sorry guys, not my fault.
This problem wasn't making any sense.
I am using Eclipse Europa with JBossTools to do all my reverse engineering, and sometimes Eclipse just close itself because of an error, so I though this problem could be something related to JBossTools. So, somehow my changes in my reveng.xml file wasn't been noticed by hibernate, i started refreshing my app and I used the source view of reveng.xml file to edit it, instead of the fancy graphical jbosstool and now it is working!!!

Thanks anyway!
 
ranger
Posts: 17347
11
Mac IntelliJ IDE Spring
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Glad we could help.

Mark
 
It's weird that we cook bacon and bake cookies. Eat this tiny ad:
a bit of art, as a gift, that will fit in a stocking
https://gardener-gift.com
reply
    Bookmark Topic Watch Topic
  • New Topic