select count(id) as totalentries, min(posted) as firstentry, max(posted) as lastentry from tblblogentries where tblblogentries.blog = select count(email) as totalsubscribers from tblblogsubscribers where tblblogsubscribers.blog = and verified = 1 select sum(views) as total from tblblogentries where tblblogentries.blog = select top 10 id, title, views from tblblogentries where tblblogentries.blog = and rownum <= 10 order by views desc limit 10 select count(id) as totalentries from tblblogentries where tblblogentries.blog = and posted >= select count(tblblogcomments.id) as totalcomments from tblblogcomments, tblblogentries where tblblogcomments.entryidfk = tblblogentries.id and tblblogentries.blog = and tblblogcomments.moderated = 1 select count(tblblogtrackbacks.id) as totaltrackbacks from tblblogtrackbacks, tblblogentries where tblblogtrackbacks.entryid = tblblogentries.id and tblblogentries.blog = select categoryid, categoryname, count(categoryidfk) as total from tblblogcategories, tblblogentriescategories where tblblogentriescategories.categoryidfk = tblblogcategories.categoryid and tblblogcategories.blog = group by tblblogcategories.categoryid, tblblogcategories.categoryname order by total desc order by count(categoryidfk) desc select top 10 tblblogentries.id, tblblogentries.title, count(tblblogcomments.id) as commentcount from tblblogentries, tblblogcomments where tblblogcomments.entryidfk = tblblogentries.id and rownum <= 10 and tblblogentries.blog = and tblblogcomments.moderated = 1 group by tblblogentries.id, tblblogentries.title order by commentcount desc order by count(tblblogcomments.id) desc limit 10 select top 10 tblblogcategories.categoryid, tblblogcategories.categoryname, count(tblblogcomments.id) as commentcount from tblblogcategories, tblblogcomments, tblblogentriescategories where tblblogcomments.entryidfk = tblblogentriescategories.entryidfk and rownum <= 10 and tblblogentriescategories.categoryidfk = tblblogcategories.categoryid and tblblogcategories.blog = and tblblogcomments.moderated = 1 group by tblblogcategories.categoryid, tblblogcategories.categoryname order by commentcount desc order by count(tblblogcomments.id) desc limit 10 select top 10 tblblogentries.id, tblblogentries.title, count(tblblogtrackbacks.id) as trackbackcount from tblblogentries, tblblogtrackbacks where tblblogtrackbacks.entryid = tblblogentries.id and tblblogentries.blog = and rownum <= 10 group by tblblogentries.id, tblblogentries.title order by trackbackcount desc order by count(tblblogtrackbacks.id) desc limit 10 select top 10 searchterm, count(searchterm) as total from tblblogsearchstats where blog = and rownum <= 10 group by searchterm order by total desc order by count(searchterm) desc limit 10 select count(tblblogcomments.email) as emailCount, email, tblblogcomments.name from tblblogcomments, tblblogentries where tblblogcomments.entryidfk = tblblogentries.id and tblblogentries.blog = group by tblblogcomments.email, tblblogcomments.name order by emailCount desc order by count(tblblogcomments.email) desc
#rb("contents")#

#rb("generalstats")#
#rb("totalnumentries")#: #getTotalEntries.totalEntries#
#rb("last30")#: #last30.totalEntries#
#rb("last30avg")#: #numberFormat(last30.totalEntries/30,"999.99")# 
#rb("firstentry")#: #dateFormat(getTotalEntries.firstEntry,"mm/dd/yy")# 
#rb("lastentry")#: #dateFormat(getTotalEntries.lastEntry,"mm/dd/yy")# 
#rb("bloggingfor")#: #dur# #rb("days")# 
#rb("totalcomments")#: #getTotalComments.totalComments#
#rb("avgcommentsperentry")#: #numberFormat(averageCommentsPerEntry,"999.99")#
#rb("totaltrackbacks")#: #getTotalTrackbacks.totalTrackbacks#
#rb("totalviews")#: #getTotalViews.total#
#rb("avgviews")#: #numberFormat(gettotalviews.total/gettotalentries.totalentries,"999.99")# 0
#rb("totalsubscribers")#: #getTotalSubscribers.totalsubscribers#

#rb("topviews")#
#title# #views#

#rb("categorystats")#
#categoryname# #total#

#rb("topentriesbycomments")#
#title# #commentCount#

#rb("topcategoriesbycomments")#
select total from getCategoryCount where categoryid = '#categoryid#'
#categoryname# #commentCount# (#rb("avgcommentperentry")#: #avg#)

#rb("topentriesbytrackbacks")#
#title# #trackbackCount#

#rb("topsearchterms")#
#searchterm# #total#

#rb("topcommenters")#
#name# #emailcount#