Add in new JDatabase queries to stats module