{
_shirts: [
{
colour: "red",
size: "large"
},
{
colour: "blue",
size: "medium"
}
]
}
Hi!
Suppose I have a bunch of clothingStore
objects that are structured as given in the example above. Each clothingStore
sells an array of shirts
, where each individual shirt
can have a colour
property and a size
property.
Is there a way for me to filter for stores that sell, for example, large blue shirts?
I have tried using a conjunction of filters against the _shirts.colour
AND _shirts.size
fields, but the conjunction of these filters seems to hit clothingStore
s so long as each filtered field is individually matched by at least one shirt
item.
For another way of putting it…
What I Want: Find all clothing stores that sell large, blue T-shirts.
What I Don’t Want: Find all clothing stores that sell large T-shirts and blue T-shirts.
Any help would be appreciated. Cheers!