openjpa-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Flemming Behrend <...@topdanmark.dk>
Subject How to add to the where clause
Date Fri, 09 Jan 2009 16:30:29 GMT

Hello

Iam writing an application where all my tables contain a column that define
if the row is soft deleted.

Is there a way in openjpa where I can specify that I only want rows returned
that are not soft deleted.

I was thinking about the equivalent operation of the hibernate element
<class> that can contain the where="arbitrary sql where condition" attribute
to specify a condition to be used when retrieving objects of a class.

I was thinking something like

@Entity
@Where(E_DEL="false")
public class Myclass {

  .....

}

Kind regards

Flemming Behrend
-- 
View this message in context: http://n2.nabble.com/How-to-add-to-the-where-clause-tp2134038p2134038.html
Sent from the OpenJPA Users mailing list archive at Nabble.com.


Mime
View raw message