• 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 tables.reveng.xml oracle sequence

 
Ranch Hand
Posts: 86
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I'm trying to add a primary key section to my tables.reveng.xml file so I generate Hibernate classes that automatically use an Oracle sequence for the primary column ID.

I got it working by hacking the following into my QUESTION_TYPE class:



Obviously this isn't the file I want to be hand-editing.

I tried to add the appropriate XML to the tables.revend.xml file. I can make no sense of the documentation. I don't understand what values it wants.

In my tiny world, there are only 2 values - the oracle sequence name (SEQ_QUESTION_TYPE_ID) and the table column to be assigned (ID.)



When I regenerate my classes using the XML above, I get no errors, the classes are rebuilt, but the QuestionType class isn't changed to reflect my sequence. I'd expect *something* to change, or an error.

Would someone throw me a bone please, whether it's the answer or a relevant doc page, I don't care. But the documents I have read so far have been unhelpful except for syntax.



 
Tony Ennis
Ranch Hand
Posts: 86
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I have no evidence that the <table> section is being processed at all. Is there a way to dump the table names that aren't filtered away?
 
Tony Ennis
Ranch Hand
Posts: 86
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
For whatever reason, I had to supply the schema in the <table param.

 
Politics n. Poly "many" + ticks "blood sucking insects". 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