config-bindingError.yaml 573 字节
Newer Older
G
gaohongtao 已提交
1 2 3 4 5
tables:
  t_order: 
    actualTables: t_order_${0..1}
    databaseStrategy: &db001
      shardingColumns: order_id
T
terrymanu 已提交
6
      algorithmClassName: com.dangdang.ddframe.rdb.sharding.config.yaml.algorithm.SingleAlgorithm
G
gaohongtao 已提交
7 8 9 10 11 12 13 14 15 16 17 18
    tableStrategy: &table001
      shardingColumns: id
      algorithmExpression: t_order_${id.longValue() % 2}
        
  t_order_item:
    actualTables: t_order_item_${0..1}
    #绑定表中其余的表的策略与第一张表的策略相同
    databaseStrategy: *db001
    tableStrategy: *table001

bindingTables:
  - tableNames: t_order,t_order_no_exist