The query engine doesn't have orElse semantic; spring may be generating
appropriate query based on the condition...

I assume you are getting zero results for your query; And you are expecting
to get one results with maturity value 200.

-Anil.


On Sat, Nov 4, 2017 at 4:09 AM, Dharam Thacker <[email protected]>
wrote:

> I found orElse keyword usage in spring data geode but would like to know
> if it's natively supported in oql query grammer.
>
> getPersonRepository().findById(id).orElse(null);
>
>
> Thanks,
> Dharam
>
> On Nov 4, 2017 00:26, "Dharam Thacker" <[email protected]> wrote:
>
> Hi,
>
> could some one help me to design oql query?
>
> Here is the region structure as Region <String,PdxInstance>
> Key1 -> [*index=100*,maturity=*200*]
> Key2 -> [index=100,*maturity=100*]
>
> I am trying to design a query to *get index based on maturity...*
>
> select i.index from /data i where i.maturity=200 and *not* (i.index in
> set (select i1.maturity from /data i2)) [This works well for step1 and
> filters result for step2 but does not give answer for step2]
>
> 1. Get maturity based on index [Simple rule]
> 2. But if step1 gives index which itself is maturity anywhere, then simply
> output incoming maturity as it is [So in this case 200]
>
> Thanks,
> - Dharam Thacker
>
>
>

Reply via email to