Hello:
I need to access from Grails to several different tables that are in different schemas. The user has access permissions to all the tables, but , when I try to map the Domain classses to the tables, I can't find a way to get it done.
I've tried to map the domain this way:
static mapping = {
table 'SCHEMA2.TABLE'
//Table columns and mapping
...
}
I can also change the default schema on the DataSource file, but in this case I keep accessing only one of the two schemas
hibernate.default_schema = 'schema2'
We've make alias to acess the tables in schema2 from schema1, but I think there should be a way to do this, without having to define all the mapping with Hibernate (I really don't like XML files)