vintox Posted May 21, 2009 Share Posted May 21, 2009 there is a way to combine multiple counts or sum from multiple tables? i tried this query but it returns the last "count(r.id)" for all of the three SELECT COUNT(m.id) as unum,COUNT(p.id) as pnum, COUNT(r.id) as rnum FROM members as m, posts as p, reply as r Quote Link to comment https://forums.phpfreaks.com/topic/159054-solved-multiple-counts-in-one-query/ Share on other sites More sharing options...
luca200 Posted May 21, 2009 Share Posted May 21, 2009 I don't think so Quote Link to comment https://forums.phpfreaks.com/topic/159054-solved-multiple-counts-in-one-query/#findComment-838817 Share on other sites More sharing options...
fenway Posted May 22, 2009 Share Posted May 22, 2009 Sure there is... so how did you solve it? Quote Link to comment https://forums.phpfreaks.com/topic/159054-solved-multiple-counts-in-one-query/#findComment-840066 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.