I have models in the index (Azure), like:
[
{ list: ['1', '2', '3'] },
{ list: ['1', '3'] },
{ list: ['5', '5', '5'] },
{ list: ['1'] }
]
I need to find data where this property (list) has only one exact item '1' using queries (filter), how to make it?
My variants were to use queries:
- Use
$filter=list/any(item: item eq '1') and list/$count eq 1, but it seems like there is no such a thing, as count of the items in the collection. - Use
$filter=list/all(item: item eq '1')just to be sure all items are the same (for me it's a tradeoff and I can use it), buteqis not allowed insideall. - Use wildcard patterns
$filter=list/all(item: not search.ismatch('<inversed ignore pattern>', item, 'full', 'all')), butsearch.ismatchis not supported inside lambda expressions
How to make it?