hi,
report query is the way to go:
ReportQueryByCriteria query;
Criteria crit;
System.out.println("\nreport (sum(test) with name like '%er'");
crit = new Criteria();
crit.addLike("name", "%er");
query = new ReportQueryByCriteria(Person.class, crit);
query.setColumns(new String[] { "max(test)" });
broker.getReportQueryIteratorByQuery(query);
hth
jakob
Stefan Schl�sser wrote:
On 13 Feb 2003 at 12:21, Mahler Thomas wrote:
getCount does exist for OJB internal purposes.
I hope this does not mean it will be deleted from the interface at
some point ...
If you want to work with resulsets instead with full entity objects use the
reportquery mechanism.
I would very much like to know more on how the reportquery works, but
the section in the mentioned link
(see http://db.apache.org/ojb/query.html)
is empty.
To me it seems that the ReportQuery is just what I need since it is
based on the repository and allows freeform sql a la min/max. I do
not want to create objects based on such sql functions. They are just
needed in a general database layer, which is a role OJB in mho can
fulfill quite well.
Cheer,
Stefan
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]