Discussion:
[jboss-user] [JBoss Tools] - Hibernate Tools ignoring reverse engineering package=".." in table-filter
Ravindar Reddy
2013-05-09 17:20:15 UTC
Permalink
Ravindar Reddy [https://community.jboss.org/people/rroopreddy] created the discussion

"Hibernate Tools ignoring reverse engineering package=".." in table-filter"

To view the discussion, visit: https://community.jboss.org/message/817044#817044

--------------------------------------------------------------
Working with Eclipse with Tools version 3.6.0.Final-v20130327
With MySQL 5.6.x version with InnoDB dialect

My file looks like the following

<?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" >


  <!--  These are from entity.common included to generate proper reference package name  -->
  <table-filter match-catalog="entity" match-name="status_code" package="entity.common" />

<!--  These are from entity.person included to generate proper reference package name  -->
  <table-filter match-catalog="entity" match-name="person" package="entity.person" />

</hibernate-reverse-engineering>

I left the default package in GUI empty as I have the "package" specified for each table-filter. Code for the above two files are generated into "default" package and not into respective "entity.common", "entity.person". If I specify the default package in GUI then both classes are generated into that package.

Somehow the package specified in reverse engineering file is ignored
--------------------------------------------------------------

Reply to this message by going to Community
[https://community.jboss.org/message/817044#817044]

Start a new discussion in JBoss Tools at Community
[https://community.jboss.org/choose-container!input.jspa?contentType=1&containerType=14&container=2128]
Ravindar Reddy
2013-05-10 17:19:14 UTC
Permalink
Ravindar Reddy [https://community.jboss.org/people/rroopreddy] created the discussion

"Re: Hibernate Tools ignoring reverse engineering package=".." in table-filter"

To view the discussion, visit: https://community.jboss.org/message/817186#817186

--------------------------------------------------------------
Workaround, removing  -- match-catalog="entity" -- from table-filter seems to work for now.
Things seem to silently fail with case sensitivity on MySQL
--------------------------------------------------------------

Reply to this message by going to Community
[https://community.jboss.org/message/817186#817186]

Start a new discussion in JBoss Tools at Community
[https://community.jboss.org/choose-container!input.jspa?contentType=1&containerType=14&container=2128]
Max Rydahl Andersen
2013-05-13 12:43:54 UTC
Permalink
Max Rydahl Andersen [https://community.jboss.org/people/maxandersen] created the discussion

"Re: Hibernate Tools ignoring reverse engineering package=".." in table-filter"

To view the discussion, visit: https://community.jboss.org/message/817388#817388

--------------------------------------------------------------
mysql has a funky concept of catalog thus make sure you actual have a database named "entity" before trying to match it.
--------------------------------------------------------------

Reply to this message by going to Community
[https://community.jboss.org/message/817388#817388]

Start a new discussion in JBoss Tools at Community
[https://community.jboss.org/choose-container!input.jspa?contentType=1&containerType=14&container=2128]
Loading...