First of all sry due to English not being my first language.
Am I able to do REFERENCES ,JOINS and other operations in between schemas with this framework?
I麓m trying to wrap my head around it but I can only create tables in different schemas using this bit of code just before the create operation
fun Transaction.setSchema(schema: DatabaseSchemas){
exec("set SEARCH_PATH TO \"$schema\"")
}
transaction {
setSchema(DatabaseSchemas.XXXXXXX)
createMissingTablesAndColumns(UsersTable)
}
where DatabaseSchemas is an Enum of all My Schemas (done this way for ease of use)
@Hgmoa , Exposed doesn't support cross-schema interaction atm, but you can try to add schema to table name. I'm not sure that it will work, but plz give it a try and tell me if it helps you.
object Foo : IdTable("Schema.Foo) {}
object Bar : Table {
val foo by optReference("foo", Foo)
}
@Hgmoa , any news? Was it possible to find any workaround for you problem with cross-schema relationships?
I need to use another schema than public. Is there any way to do it atm?
You may try this and leave feedback if that helps.
@Tapac I tried your suggestion and it worked fine for me, i was able to join tables from different schemas
I wrote table name like schema.table in table name, and it worked fine! It worked) tested on PostgreSQL
Most helpful comment
@Tapac I tried your suggestion and it worked fine for me, i was able to join tables from different schemas