• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Hibernate tables.reveng.xml oracle sequence

 
Tony Ennis
Ranch Hand
Posts: 86
  • 0
  • Mark post as helpful
  • send pies
  • 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
  • 0
  • Mark post as helpful
  • send pies
  • 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
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
For whatever reason, I had to supply the schema in the <table param.

 
Consider Paul's rocket mass heater.
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic