thswlsqls opened a new issue, #39099: URL: https://github.com/apache/shardingsphere/issues/39099
## Bug Report ### Which version of ShardingSphere did you use? master @ 620e40a33c3 ### Which project did you use? ShardingSphere-JDBC or ShardingSphere-Proxy? Both (kernel-level binder) ### Expected behavior Under the SQL92 baseline dialect, the niladic function `SYSTEM_USER` should bind as a function, like the sibling SQL-92 ยง6.8 user-value functions `USER`, `CURRENT_USER`, and `SESSION_USER`. ### Actual behavior `SYSTEM_USER` is missing from `SQL92FunctionOption.UNPARENTHESIZED_FUNCTION_NAMES`, so the binder misclassifies it as a column reference instead of a function. ### Reason analyze (If you can) `SQL92FunctionOption` (database/connector/dialect/sql92/.../metadata/database/option/SQL92FunctionOption.java line 31-32) lists only 3 of the 4 SQL-92 user-value niladic functions. `ColumnSegmentBinder.isUnparenthesizedFunction()` (infra/binder/core/.../expression/type/ColumnSegmentBinder.java line 143) reads this set via `.contains()` to decide function vs column. The MySQL and SQLServer sibling options already include `SYSTEM_USER`. ### Steps to reproduce the behavior, such as: SQL to execute, sharding rule configuration, when exception occur etc. Bind `SELECT SYSTEM_USER` against a SQL92-typed schema; the identifier is treated as a column rather than a niladic function. ### Example codes for reproduce this issue (such as a github link). N/A -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
