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

   ## Bug Report
   
   ### Which version of ShardingSphere did you use?
   master 
[dd44eb00aba6f63efdba6f](https://github.com/apache/shardingsphere/commit/dd44eb00aba6f63efdba6feb8ddb5845fcc5152a)
   ### Which project did you use? ShardingSphere-JDBC or ShardingSphere-Proxy?
   ShardingSphere-Proxy
   ### Expected behavior
   Correct execution result and return 1
   ### Actual behavior
   `ERROR 10007 (42S02): Table or view `cte` does not exist.`
   
![12346](https://github.com/apache/shardingsphere/assets/106047330/bf5fb6ca-dec0-499e-9787-a68635789757)
   
   ### Reason analyze (If you can)
   `SimpleTableSegmentBinder.java`
   
![QQ20231102-175243](https://github.com/apache/shardingsphere/assets/106047330/d83145f8-4c30-4eb5-b56b-ffa169c94364)
   
   ### Steps to reproduce the behavior, such as: SQL to execute, sharding rule 
configuration, when exception occur etc.
   mysql version: 8.0.27
   
   `server.yaml`
   ```
   mode:
     type: Cluster
     repository:
       type: ZooKeeper
       props:
         namespace: poc_sharding
         server-lists: 127.0.0.1:2181
         retryIntervalMilliseconds: 500
         timeToLiveSeconds: 60
         maxRetries: 3
         operationTimeoutMilliseconds: 500
   
   sqlFederation:
     sqlFederationEnabled: true
     executionPlanCache:
       initialCapacity: 2000
       maximumSize: 65535
   ```
   ```
   create database test;
   
   use test;
   
   REGISTER STORAGE UNIT ds_0 (
       
URL="jdbc:mysql://127.0.0.1:3304/test_db?serverTimezone=UTC&useSSL=false&allowPublicKeyRetrieval=true",
       USER="root",
       PASSWORD="root",
       PROPERTIES("maximumPoolSize"="10","idleTimeout"="30000")
   );
   
   with cte as (select 1) select * from cte;
   ```
   ### Example codes for reproduce this issue (such as a github link).
   


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