I did check those out, but the limitation is that they are based on prepared 
statements that have a fixed where clause. I need to be able to construct an 
arbitrary list of fields that are included in the where clause only if the 
value associated with them is not null. Is there a way to do this with the pre 
made queries referred to by QueryDefault?

Jeremy


On Aug 27, 2013, at 11:24 AM, Kevin Meyer - KMZ wrote:

> Hi Jeremy,
> 
> If I remember correctly, Dan has examples for overriding the "Finder" 
> methods in the ToDo demo / artefact that use JDO search classes to 
> build queries.
> 
> In fact:
> 
> In the  "ToDoItemsJdo" class (which extends an 
> AbstractFactoryAndRepository):
>    // {{ notYetComplete (action)
>    @Override
>    protected List<ToDoItem> doNotYetComplete() {
>        return allMatches(
>                new QueryDefault<ToDoItem>(ToDoItem.class, 
>                        "todo_notYetComplete", 
>                        "ownedBy", currentUserName()));
>    }
>    // }}
> 
> This appears in an old copy of the repo I have in the wicket JDO 
> quickstart project.
> 
> So while you can't use "FindByPattern", JDO has implemented a 
> useful alternative.
> 
> Regards,
> Kevin

Reply via email to