CrackerSuperior opened a new issue #13400:
URL: https://github.com/apache/shardingsphere/issues/13400


   version:
   master
   
   config:
   ``` yaml
   schemaName: test
   
   dataSources:
     ds_0:
       url: 
jdbc:mysql://127.0.0.1:3306/inserttest_0?serverTimezone=UTC&useSSL=false
       username: pcloud
       password: pcloud
       connectionTimeoutMilliseconds: 30000
       idleTimeoutMilliseconds: 60000
       maxLifetimeMilliseconds: 1800000
       maxPoolSize: 50
       minPoolSize: 1
     ds_1:
       url: 
jdbc:mysql://127.0.0.1:3306/inserttest_1?serverTimezone=UTC&useSSL=false
       username: pcloud
       password: pcloud
       connectionTimeoutMilliseconds: 30000
       idleTimeoutMilliseconds: 60000
       maxLifetimeMilliseconds: 1800000
       maxPoolSize: 50
       minPoolSize: 1
   
   rules:
     - !SHARDING
       tables:
         insertTest:
           actualDataNodes: ds_${0..1}.inserttest
           keyGenerateStrategy:
             column: sharding
             keyGeneratorName: snowflake
         insert3:
           actualDataNodes: ds_${0..1}.insert3
           keyGenerateStrategy:
             column: sharding
             keyGeneratorName: snowflake
         insert4:
           actualDataNodes: ds_${0..1}.insert4
           keyGenerateStrategy:
             column: sharding
             keyGeneratorName: snowflake
         insert5:
           actualDataNodes: ds_${0..1}.insert5
           keyGenerateStrategy:
             column: sharding
             keyGeneratorName: snowflake
         insert6:
           actualDataNodes: ds_${0..1}.insert6
           keyGenerateStrategy:
             column: sharding
             keyGeneratorName: snowflake
         insert7:
           actualDataNodes: ds_${0..1}.insert7
           keyGenerateStrategy:
             column: sharding
             keyGeneratorName: snowflake
         insert8:
           actualDataNodes: ds_${0..1}.insert8
           keyGenerateStrategy:
             column: sharding
             keyGeneratorName: snowflake
         insert9:
           actualDataNodes: ds_${0..1}.insert8
           keyGenerateStrategy:
             column: sharding
             keyGeneratorName: snowflake
       defaultDatabaseStrategy:
         standard:
           shardingColumn: sharding
           shardingAlgorithmName: database_inline
       defaultTableStrategy:
         none:
   
       shardingAlgorithms:
         database_inline:
           type: INLINE
           props:
             algorithm-expression: ds_${sharding % 2}
   
       keyGenerators:
         snowflake:
           type: SNOWFLAKE
           props:
             worker-id: 123
   ```
   
   result:
   ``` sql
   mysql> select * from inserttest union select * from insert3;
   ERROR 1997 (C1997): Runtime exception: [SELECT ... UNION statement can not 
support sharding tables or broadcast tables.]
   ```
   
   


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