TeslaCN opened a new issue, #25879:
URL: https://github.com/apache/shardingsphere/issues/25879

   ## Bug Report
   
   ### Which version of ShardingSphere did you use?
   
   5.3.2
   
   ### Which project did you use? ShardingSphere-JDBC or ShardingSphere-Proxy?
   
   Proxy
   
   ### Expected behavior
   
   MySQL 8.0.19 TABLE statement worked.
   
   https://dev.mysql.com/doc/refman/8.0/en/table.html
   
   ### Actual behavior
   
   ```
   mysql> table f;
   ERROR 30000 (HY000): Unknown exception: Cannot invoke 
"org.apache.shardingsphere.sql.parser.sql.common.segment.dml.item.ProjectionsSegment.isDistinctRow()"
 because the return value of 
"org.apache.shardingsphere.sql.parser.sql.common.statement.dml.SelectStatement.getProjections()"
 is null
   mysql> table f order by id;
   ERROR 30000 (HY000): Unknown exception: Cannot invoke 
"org.apache.shardingsphere.sql.parser.sql.common.segment.dml.item.ProjectionsSegment.getProjections()"
 because "projectionsSegment" is null
   ```
   
   ```
   [ERROR] 2023-05-25 13:55:24.830 [ShardingSphere-Command-1] 
o.a.s.p.f.c.CommandExecutorTask - Exception occur: 
   java.lang.NullPointerException: Cannot invoke 
"org.apache.shardingsphere.sql.parser.sql.common.segment.dml.item.ProjectionsSegment.getProjections()"
 because "projectionsSegment" is null
        at 
org.apache.shardingsphere.infra.binder.segment.select.projection.engine.ProjectionsContextEngine.getProjections(ProjectionsContextEngine.java:76)
        at 
org.apache.shardingsphere.infra.binder.segment.select.projection.engine.ProjectionsContextEngine.createProjectionsContext(ProjectionsContextEngine.java:67)
        at 
org.apache.shardingsphere.infra.binder.statement.dml.SelectStatementContext.<init>(SelectStatementContext.java:118)
        at 
org.apache.shardingsphere.infra.binder.SQLStatementContextFactory.getDMLStatementContext(SQLStatementContextFactory.java:166)
        at 
org.apache.shardingsphere.infra.binder.SQLStatementContextFactory.newInstance(SQLStatementContextFactory.java:149)
        at 
org.apache.shardingsphere.infra.binder.SQLStatementContextFactory.newInstance(SQLStatementContextFactory.java:134)
        at 
org.apache.shardingsphere.proxy.backend.handler.ProxyBackendHandlerFactory.getDatabaseAdminBackendHandler(ProxyBackendHandlerFactory.java:284)
        at 
org.apache.shardingsphere.proxy.backend.handler.ProxyBackendHandlerFactory.newInstance(ProxyBackendHandlerFactory.java:122)
        at 
org.apache.shardingsphere.proxy.frontend.mysql.command.query.text.query.MySQLComQueryPacketExecutor.<init>(MySQLComQueryPacketExecutor.java:69)
        at 
org.apache.shardingsphere.proxy.frontend.mysql.command.MySQLCommandExecutorFactory.newInstance(MySQLCommandExecutorFactory.java:78)
        at 
org.apache.shardingsphere.proxy.frontend.mysql.command.MySQLCommandExecuteEngine.getCommandExecutor(MySQLCommandExecuteEngine.java:64)
        at 
org.apache.shardingsphere.proxy.frontend.command.CommandExecutorTask.executeCommand(CommandExecutorTask.java:109)
        at 
org.apache.shardingsphere.proxy.frontend.command.CommandExecutorTask.run(CommandExecutorTask.java:77)
        at com.alibaba.ttl.TtlRunnable.run(TtlRunnable.java:60)
        at 
java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1136)
        at 
java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:635)
        at java.base/java.lang.Thread.run(Thread.java:833)
   ```
   


-- 
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]

Reply via email to