-->
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.  [ 3 posts ] 
Author Message
 Post subject: schema missing in generated EJB3 annotations
PostPosted: Thu Nov 16, 2006 12:50 pm 
Newbie

Joined: Thu Nov 16, 2006 12:34 pm
Posts: 2
Hi there!

Basic Description:
I´m currently trying to reverse engineer POJOs out of an existing database. Generation works so far, but I´m missing the "schema" attribute in my generated annotations.

Details:
I´m running Oracle9 and have several schemas in my DB instance. I want to generate the POJOs for a schema which is not the default one.

So basically what I did was to generate the following reverse.enginieering.xml:

Code:
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE hibernate-reverse-engineering PUBLIC "-//Hibernate/Hibernate Reverse Engineering DTD 3.0//EN" "http://hibernate.sourceforge.net/hibernate-reverse-engineering-3.0.dtd" >

<hibernate-reverse-engineering>
  <schema-selection match-schema="ALTERNATE_SCHEMA" ></schema-selection>
</hibernate-reverse-engineering>


Tables are only considered for reverseengineering if they are in the given schema. So I think the basic selection works just fine. But the classes that get generated only have the following table-annotation:

Code:
@Table(name = "SOME_TABLE")


In my understanding the annotation should also have an additional "schema" attribute.

I tested with generation of .hbm.xmls and these also lack the schema information. So I guess I´m missing something.

Do I have to set some additional flag or something in one of the reverseengineering dialogs? Or can I add something to the reverse-engineering.xml to make this happen?

Any advise would be appreciated.

Michael


Top
 Profile  
 
 Post subject:
PostPosted: Fri Nov 17, 2006 5:01 am 
Newbie

Joined: Thu Nov 16, 2006 12:34 pm
Posts: 2
Never mind. I took a fresh approach this morning. I accidentally still had the default schema set to the one I was missing.


Top
 Profile  
 
 Post subject:
PostPosted: Fri Nov 17, 2006 11:55 am 
Hibernate Team
Hibernate Team

Joined: Tue Aug 26, 2003 6:10 am
Posts: 8615
Location: Neuchatel, Switzerland (Danish)
exactly ;)

_________________
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.  [ 3 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.