So let's say my collection looks something like this:
interface MyCollection {
myArray: {
myNumberField: number;
id?: string;
}[]
}
I want to get all documents where myNumberField
contains a number of [1,2,3]
. How would the where query look here? I can't seem to find a solution on https://payloadcms.com/docs/queries/overview#operators
got it to work, if anyone needs this later:
where: {
'myArray.myNumberField': {
in: [1,2,3]
}
}
Star
Discord
online
Get dedicated engineering support directly from the Payload team..