Is it possible to execute the following query as one query?
[code]
select count(*) from tableA;
select count(*) from tableB;
select count(*) from tableC;
select count(*) from tableD;
[/code]
ie. the result to be something like this
|TablA|TableB|TableC|TableD|
|50 |300 |30 |9|
Thanks
select * from
(select count(*) from tableA),
(select count(*) from tableB),
(select count(*) from tableC),
(select count(*) from tableD);
Yes
select count(*) from tableA;
union all
select count(*) from tableB;
union all
select count(*) from tableC;
union all
select count(*) from tableD;
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With