[orientdb] Re: Can't get a query with CONTAINSALL to work

2015-07-31 Thread alessandrorota04
Hi, you can use this query: select from Person where $parents containsAll (@rid in $current.in_Child) and $parents.size() = in('Child').size() and @rid<>#11:3 let $parents= (select expand(in('Child')) from #11:3) Regards, Alessandro -- --- You received this message because you are subscribed

[orientdb] Re: Can't get a query with CONTAINSALL to work

2015-07-30 Thread neRok
Okay, I think it is starting to make sense. If my understanding is correct, when you are within the containsall expression, you are 'working with' each person record from the current 'children' rid collection? So when you are checking the 'married' property, it is actually checking children[0].

[orientdb] Re: Can't get a query with CONTAINSALL to work

2015-07-30 Thread alessandrorota04
Hi, This example should help : select from Person where children contains ( married = true ) // select people who have at least one child with married = true select from Person where children containsAll ( married = true ) // select people who have all the children with married = true Regards, A

[orientdb] Re: Can't get a query with CONTAINSALL to work

2015-07-29 Thread neRok
Thanks for the reply. I never noticed it until now, when I am trying to do something similar again. I understand what you are saying, but I can't fathom the syntax. Can you give an example? On Thursday, 14 May 2015 12:31:47 UTC+8, Ziink A wrote: > > I know this is a very late response but it's

[orientdb] Re: Can't get a query with CONTAINSALL to work

2015-05-13 Thread Ziink A
I know this is a very late response but it's mostly for someone who's looking as I was. ContainsAll implies that the collection on the left 'contains all' the items on the right. THAT IS NOT SO. On the right of CONTAINSALL should be a condition. All elements in the set on the left must satis