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 2020/12/30 03:32:13 UTC

[GitHub] [shardingsphere] NOLouser opened a new issue #8820: does shardingsphere support several sharding strategies for one table ?

NOLouser opened a new issue #8820:
URL: https://github.com/apache/shardingsphere/issues/8820


   for example:
         I have several tables
               logic table:  t_order(order_id, order_msg, create_time)
               sharding tables:  t_order_202001、t_order_202002、t_order_202003 ....
         I want to set PreciseShardingAlgorithm for sharding key: order_id (sql like: query by order_id), and I also want to force sql to the table that I specify( by using HintShardingAlgorithm, sql like: specify query table t_order_202001 ).
   
   I tried to set my PreciseShardingAlgorithm and HintShardingAlgorithm to the shrading rule config, however, only one sharding algorithm would work. Does this mean not support several sharding strategies for the same table?
   
   


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

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



[GitHub] [shardingsphere] NOLouser commented on issue #8820: does shardingsphere support several sharding strategies for one table ?

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


   I get it! 
   
   Thanks a lot!


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

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



[GitHub] [shardingsphere] tristaZero commented on issue #8820: does shardingsphere support several sharding strategies for one table ?

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


   Hi, @NOLouser ,
   
   You can not configure two sharding algorithms for one logic table in a direct way. However, creating two different logic tables sharding the same actual tables (i.e., two different sharding algorithm for the same actual data nodes) is possible to meet your needs. Be careful with this usage, It is not a regular one.


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

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



[GitHub] [shardingsphere] NOLouser closed issue #8820: does shardingsphere support several sharding strategies for one table ?

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


   


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

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