Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Syntax error when generating code on Informix 12.10 #8417

Open
lukaseder opened this Issue Mar 14, 2019 · 0 comments

Comments

Projects
None yet
1 participant
@lukaseder
Copy link
Member

lukaseder commented Mar 14, 2019

It appears that on older Informix versions, the "informix"."systables" table cannot be accessed when quoted:

[WARNING] SQL exception            : Exception while executing meta query: A syntax error has occurred.
select distinct trim("informix"."systables"."owner")
from "informix"."systables"
where "informix"."systables"."owner" in ('<schema name>')

[ERROR] Could not load schemata  
org.jooq.exception.DataAccessException: SQL [select distinct trim("informix"."systables"."owner") from "informix"."systables" where "informix"."systables"."owner" in (cast(? as lvarchar)) -- SQL rendered with a free trial version of jOOQ 3.11.9]; A syntax error has occurred.
     at org.jooq_3.11.9.INFORMIX.debug(Unknown Source)
     at org.jooq.impl.Tools.translate(Tools.java:2429)

The query works when the quotes in the from clause are removed, e.g.

select distinct trim("informix"."systables"."owner")
from informix.systables
where "informix"."systables"."owner" in ('<schema name>')```

A workaround is to provide settings to the code generator, e.g. through the classpath at /jooq-settings.xml, or via the -Dorg.jooq.settings system property

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.