We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
postpresql
16
1.2.22
openJDK 1.8
PostgreSQL支持使用Hint expand进行性能优化, 使用 druid 解析带 Hint 的 SQL 如下所示:
String = "INSERT INTO payments(amountNumber) select /*! no_expand */ sum(amount) from payments"; List<SQLStatement> statements = SQLUtils.parseStatements(sql, DbType.of("postgresql"))
获取 statements 中, 把原SQL语句的 /*! no_expand / Hint 片段 丢失了, 如果把 DbType.of("postgresql") 换成 DbType.of("mysql"), /! no_expand */ Hint 片段不会丢失。
通过查看 druid 源码, 发现 MySqlSelectParser 对 Token.HINT 有相关的处理。 而 PGSelectParser 并没有发现 Token.HINT 的代码处理逻辑。
请问 druid 是否支持 PostgreSQL支持使用Hint ? 如果能支持,请指出问题哪弄错了?
No response
The text was updated successfully, but these errors were encountered:
如果不能支持,能否考虑后续的版本 druid 支持 PostgreSQL支持使用Hint
Sorry, something went wrong.
No branches or pull requests
Database Type
postpresql
Database Version
16
Druid Version
1.2.22
JDK Version
openJDK 1.8
Error SQL
PostgreSQL支持使用Hint expand进行性能优化, 使用 druid 解析带 Hint 的 SQL 如下所示:
获取 statements 中, 把原SQL语句的 /*! no_expand / Hint 片段 丢失了, 如果把 DbType.of("postgresql") 换成 DbType.of("mysql"), /! no_expand */ Hint 片段不会丢失。
通过查看 druid 源码, 发现 MySqlSelectParser 对 Token.HINT 有相关的处理。 而 PGSelectParser 并没有发现 Token.HINT 的代码处理逻辑。
请问 druid 是否支持 PostgreSQL支持使用Hint ? 如果能支持,请指出问题哪弄错了?
Testcase Code
No response
Stacktrace Info
No response
Error Info
No response
The text was updated successfully, but these errors were encountered: