-1
我將如何結合這些查詢? 「已刪除」字段是指示何時「刪除」主題的時間戳。該主題並未真正被刪除。如果它有實際的時間戳,我只是不會顯示它。關係數據庫查詢
$topics = "SELECT id FROM topics WHERE deleted = '0000-00-00 00:00:00'";
$comments = "SELECT * FROM comments WHERE topic_id IN($topics)";