Gayner Posted November 16, 2009 Share Posted November 16, 2009 $sql1 = "SELECT count(*) AS num_replies FROM `forum_topics` WHERE `cid`='".$row3['cid']."'"; I want to beable to have num_replies and num_posts, posts are in forum_replies table tho.. ? but how? Thanks. Quote Link to comment https://forums.phpfreaks.com/topic/181699-2-as-in-query-help/ Share on other sites More sharing options...
Mchl Posted November 16, 2009 Share Posted November 16, 2009 Is there a foreign key between these tables? Quote Link to comment https://forums.phpfreaks.com/topic/181699-2-as-in-query-help/#findComment-958324 Share on other sites More sharing options...
fenway Posted November 19, 2009 Share Posted November 19, 2009 You mean the tables that we haven't seen structures for? Quote Link to comment https://forums.phpfreaks.com/topic/181699-2-as-in-query-help/#findComment-960974 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.