Hi,
I can't make default schema & default catalog to work when I'm reverse engineering with Eclipse. (Even if a assign them they don't seem to have any effect)
I have following lines on my hibernate.cfg.xml:
Code:
<hibernate-configuration>
<session-factory>
... db-settings ...
<property name="hibernate.default_catalog">CATALOG</property>
<property name="hibernate.default_schema">SCHEMA</property>
</session-factory>
</hibernate-configuration>
I got following lines in the reveng.xml but with these, the specific table configurations (property names etc) aren't used.
Code:
<table name="TABLE" class="ClassName">
... conf ...
</table>
So that results as
Quote:
2007-08-24 15:23:48,609 WARN Worker-5 org.hibernate.cfg.reveng.JDBCReader - The JDBC driver didn't report any primary key columns in TABLE. Asking rev.eng. strategy
2007-08-24 15:23:48,609 WARN Worker-5 org.hibernate.cfg.reveng.JDBCReader - Rev.eng. strategy did not report any primary key columns for TABLE
Then, after I changed my reveng.xml to include schema and catalog like following, then the configurations work fine.
Code:
<table catalog="CATALOG" schema="SCHEMA" name="TABLE"
class="ClassName">
... conf ...
</table>
So, anybody got some idea what's wrong and how I could avoid copy-pasting those catalog & schema settings to each table?
Using following:
Hibernate & Hibernate Tools 3.2.0
MS SQL Server, jTDS JDBC driver
Btw. there seems to be a typo in Hibernate Tools reference 5.2.4 section - there is written "hiberante.default_catalog" and "hiberante.default_schema". Didn't still work with them either.
Best regards,
Touko