I have a Firestore document that contains array like this:
Array: Array:
[1, 2, 3, 4, 5, 6, 7] or ['Zhangir', 'Erasyl', 'Arman']
And I need to check if this document contains any of given arrays. For Example:
[1, 2, 3, 4] or [1, 2, 7] or ['Zhangir', 'Arman'] and so on
and return it only if it has exact matches. But considering that my arrays can be 100 elements long, that would be very inconvenient to say arraycontains [1], arraycontains[2]...
each time. Is there any way to do a compound query for a lot of values?
All information that I found says I can't, but maybe there's a way.
From my example that would be
Firestore.instance.collection("Querys")
.where('array', arrayContains: [1, 2, 3, 4, 5]);
or
Firestore.instance.collection('Querys')
.where('array', arrayContains: ['Zhangir', 'Arman']);
and not something like
Firestore.instance.collection('Querys')
.where('array', arrayContains: 'Zhangir')
.where('array', arrayContains: 'Arman');