问题已解决:A表和B表有分片tenant_code(按租户分片)和分区date(按月分区),更新A表,只能按分区更新,且只能一个月一个月更新。
update tableA, tableB set
tableA.tid= tableB.tid
where tableA.tenant_code=tableB.tenant_code
and tableA.date=tableB.date
and tableA.no = tableB.no
and tableA.date>'2022-04-01' and tableA.date<'2022-04-30';
ps:期待大神们更好的解决方案~... 展开详请