1.2 introduces a new query - SingleObjectQuery, however it is not yet
ready for prime time (it was used with remote persistence stuff till
now). Still you can build your own SelectQuery, following the same
logic. It is pretty straightforward:
int id = ..;
Expression qualifier =
ExpressionFactory.matchDbExp(MyObject.ID_PK_COLUMN, new Integer
(id));
SelectQuery q = new SelectQuery(MyObject.class, qualifier);
Andrus
On Dec 6, 2005, at 11:49 PM, jah.volcano wrote:
> Hi,
>
> I am refreshing an object I have loaded to update it if the DB has
> changed it while I am looking at it. I noticed that
> DataObjectUtils.objectForPK() is caching and I would like it not
> to, or find another way to get the object by id using a query. Any
> ideas?
>
> Thanks,
> Joseph
>
This archive was generated by hypermail 2.0.0 : Tue Dec 06 2005 - 16:22:04 EST