简体   繁体   中英

Cohql - apply filter for value which is inside map or list

I am using cohql for querying cache. I have one cached object which has a Hashmap as a property. Now when get a cache using get(key) and get NamedCache object.

I want to apply filter based on some value of property which is present inside the map. I have used like this -

QueryHelper.createFilter(“Obj.map{‘propertyName’}= ‘xyz’ “)

QuertHelper.createFilter(“Obj.list[‘property’]”)

But not working.

Anybody has any idea ?

Or how we query for collection data ?

Working on complex data types in coherence cache is similar to as we work normally with Java APIs

For query map like object in cohql we can use For map -

QueryHelper.createQuery(“Obj.get(‘key’) = ‘xyz’”)

For detailed info - https://docs.oracle.com/cd/E24290_01/coh.371/e22622/strings.htm#BEIDEFED

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM