赛捷软件论坛's Archiver

erina.pan 发表于 2016-12-6 11:20

sql中将两个表中数据相加求表中总数

select sum(a) from  
(
select COUNT(*) a from _aa2    union all
select COUNT(*) a from _aa1
) c

页: [1]

Powered by Discuz! Archiver 7.2  © 2001-2009 Comsenz Inc.