分表统计查询

select sum(*) from (select count(*) NU from tab1 union select count(*) NU from tab2) temp

原文地址:https://www.cnblogs.com/isuben/p/5403618.html