Similar to
select count(*) from tablename;
what should be query in ORMLITE
i tried something like
int total = dao.queryBuilder().("select count(*)");
Similar to
select count(*) from tablename;
what should be query in ORMLITE
i tried something like
int total = dao.queryBuilder().("select count(*)");
ORMLite has a
Dao.countOf()
method that returns the total number of rows in a table:You can also count the number of rows in a custom query by calling the
countOf()
method on theWhere
orQueryBuilder
object.for package 5: you can use
countOf()
From the docs: