Exposed
Exposed copied to clipboard
Having dot symbols within table names produces incorrect SQL statements
In case a table name has a dot in it (e.g. "namespaceABC.some_entities") then the resulting SQL query won't surround the table name with the double quotes and the execution of this query will fail.
Then if one supplies the table name already being wrapped between the quotes:
object SomeEntities : IntIdTable("\"namespaceABC.some_entities\"") { ... }
the resulting SQL queries would still be incorrect, since the table name would be broken apart by query builder and translated as: "namespaceABC"."some_entities".
This problem can be observed by having and trying to access such tables in PostgreSQL.
Is there any update or workaround on this? I have the same problem.
Hey @gzukula @Gurkonier. What error do you get when the query fails for the first option (without adding the double quotes)? Just to confirm, are you creating a schema like this SchemaUtils.createSchema("namespaceABC")
before creating the table with a dot in its name?