docs: public long countBySql(String fullSql, Object[] paramValues, Type[] paramTypes){
          Session session = this.getCurrentSession();
      	Query query = session.createSQLQuery(fullSql);
      	setupQuery(query, paramValues, paramTypes, null, null);
          return ((Number)query.uniqueResult()).longValue();
      }