DotConnect dc = new DotConnect();
dc.setSQL("select count(*) as mycount,serverid,priority from dist_reindex_journal group by serverid,priority order by serverid, priority");
List<IndexJournal> journalList = new ArrayList<IndexJournal>();
List<Map<String, String>> results = dc.loadResults();
for (Map<String, String> r : results) {
IndexJournal index = new IndexJournal(r.get("serverid"),new Integer(r.get("mycount")),new Long(r.get("priority")));
journalList.add(index);
}
return journalList;
}