I am using the new Cloud Firestore in Android. So I am facing this issue in firestore. I want to query a document, which contains an id in their array fields.
for example, I have a document with a field in firestore containing an array of integers like this:
So when I have an id 66940, I can get the document and other documents which contains the id, without returning other documents which don't contain the id 66940.
Other than this approach, I can also use the id (66940) to search it in the document id. My documents id format is like this:
- 66940_88123
- 12323_66940
The idea is, to return documents which contain 66940 in their ID. I've read about a solution here, but I don't really understand how to implement it.