There is a typical situation where different tables are scattered according to different schemes in the Oracle database and are related to each other (covering all different types of relations).
How can they be represented in Hibernate using annotations, as when creating a sessionfactory descriptor for one schema, tables in this schema cannot access other related tables (the ratio of foreign keys to tables in another schema)?
An exception was thrown for a query like the following -
"from table1 as model where model.table2Name.table2column = "+foo
The exception occurs as -
org.hibernate.QueryException: could not resolve property: table2column of: com.test.table1 [from com.test.table1 as model where model.table2Name.table2column = 1]
Here table1 and table2 are present in different schemes.
java oracle hibernate schema
nitesh
source share