Discuz查询标签及带此标签的帖子总数

SQL语句:

select t.*,count(ti.tagname) as icount from pre_common_tag as t,pre_common_tagitem as ti where ti.tagname!=' ' and t.tagid=ti.tagid and t.status=0 group by ti.tagname order by icount desc


你可能感兴趣的:(Discuz查询标签及带此标签的帖子总数)