Hi Dharam, The Query engine is returning the results as expected. I don't see any issues here...
In case of query1, it is returning the top level object based on projected/result columns after applying the condition, that is "service-name" and the "dependency". Query2, is returning the low-level objects )projection list) matching the condition. In order to get the results you want, you need to iterate through the query-2 results and build a final output Map<service-name, <Collection of dependencies>> -Anil. On Wed, Feb 21, 2018 at 6:10 AM, Thacker, Dharam < [email protected]> wrote: > Hello Team, > > > > I am unable to apply any filter conditions using OQL if collection is of > type LinkedList. Below query does not work as expected. > > Below query gives me dependencies grouped at service name level and array > of depenencies under it. > > > > *Option1:* > > select service.name, service.dependencies from /Service > service,service.dependancies empd where IS_DEFINED(empd.something) > > > > *Output:* > > Each row = serviceName -> {LinkedList} > > > > *Option2:* > > If I change query like below one then it gives filtered result but I don’t > get grouped by service name at every result comes as individual element. > > > > select service.name, empd from /Service service,service.dependancies empd > where IS_DEFINED(empd.something) > > > > *Output:* > > Each row >> > > serviceName -> empd1 > > serviceName -> empd2 > > serviceName -> empd3 > > > > Is there any such limitation? > > Anything we can do to achieve this? > > > > Thanks & Regards, > > Dharam > > > > This message is confidential and subject to terms at: http:// > www.jpmorgan.com/emaildisclaimer including on confidentiality, legal > privilege, viruses and monitoring of electronic messages. If you are not > the intended recipient, please delete this message and notify the sender > immediately. Any unauthorized use is strictly prohibited. >
