You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@shardingsphere.apache.org by GitBox <gi...@apache.org> on 2021/08/30 09:13:37 UTC

[GitHub] [shardingsphere] RaigorJiang opened a new issue #12102: Make `CREATE SHARDING TABLE RULE` synax support inline expression to config `RESOURCES`

RaigorJiang opened a new issue #12102:
URL: https://github.com/apache/shardingsphere/issues/12102


   Hi community,
   
   According to [DistSQL](https://shardingsphere.apache.org/document/current/en/features/dist-sql/syntax/rdl/rdl-sharding-rule/) syntax, users need to specify the resources to be used when execute `CREATE SHARDING TABLE RULE`. 
   For example:
   ```sql
   CREATE SHARDING TABLE RULE t_order (
   RESOURCES(resource_0,resource_1),
   ...
   );
   
   ```
   
   However, since only enumeration is currently supported, it will cause inconvenience to users when there are a large number of resources, like:
   ```sql
   CREATE SHARDING TABLE RULE t_order (
   RESOURCES(resource_0,resource_1,resource_2,resource_3,resource_4,resource_5,resource_6,resource_7,resource_8,resource_9),
   ...
   ```
   
   Therefore, I want to improve `CREATE SHARDING TABLE RULE` syntax to support the configuration of resources through [inline expression](https://shardingsphere.apache.org/document/current/en/features/sharding/concept/inline-expression/), like:
   ```sql
   CREATE SHARDING TABLE RULE t_order (
   RESOURCES('resource_$->{0..9}'),
   ...
   );
   ```
   At the same time, inline expressions and enumerations are also allowed to be used together:
   ```sql
   CREATE SHARDING TABLE RULE t_order (
   RESOURCES('resource_$->{0..9}', resource_12,resource_15,"resource_$->{17..19}"),
   ...
   );
   ```
   > Notice: Inline expressions need to be enclosed in quotation marks


-- 
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: notifications-unsubscribe@shardingsphere.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [shardingsphere] tristaZero closed issue #12102: Make `CREATE SHARDING TABLE RULE` synax support inline expression to config `RESOURCES`

Posted by GitBox <gi...@apache.org>.
tristaZero closed issue #12102:
URL: https://github.com/apache/shardingsphere/issues/12102


   


-- 
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: notifications-unsubscribe@shardingsphere.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [shardingsphere] RaigorJiang commented on issue #12102: Make `CREATE SHARDING TABLE RULE` synax support inline expression to config `RESOURCES`

Posted by GitBox <gi...@apache.org>.
RaigorJiang commented on issue #12102:
URL: https://github.com/apache/shardingsphere/issues/12102#issuecomment-908185378


   Please assign to me, thanks.


-- 
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: notifications-unsubscribe@shardingsphere.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [shardingsphere] SteNicholas commented on issue #12102: Make `CREATE SHARDING TABLE RULE` synax support inline expression to config `RESOURCES`

Posted by GitBox <gi...@apache.org>.
SteNicholas commented on issue #12102:
URL: https://github.com/apache/shardingsphere/issues/12102#issuecomment-908191611


   @RaigorJiang , I have assigned this ticket to you. Please go ahead to contribute the support mentioned above.


-- 
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: notifications-unsubscribe@shardingsphere.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [shardingsphere] RaigorJiang commented on issue #12102: Make `CREATE SHARDING TABLE RULE` synax support inline expression to config `RESOURCES`

Posted by GitBox <gi...@apache.org>.
RaigorJiang commented on issue #12102:
URL: https://github.com/apache/shardingsphere/issues/12102#issuecomment-908198227


   @SteNicholas  Thank you.


-- 
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: notifications-unsubscribe@shardingsphere.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org