Hey Daniel Bächtold,

Thank your for the feedback!

I see your point, on performance, yes fully agree with you, but, in terms of costs, I’m actually not sure it is cheaper.

Isn’t Firestore counting the costs of querying a collection in the same way as per document? My understanding was that querying a document count as a “+1” and querying a collection costs as “+1 for each documents of the results”.

If that would be correct then it means that in terms of querying, my above solution would only cost one more query per fetch, the query of the parent document which contains the list of ids to fetch.

As you said, it probably depends on how big the list is.

Freelancer by day | Creator of DeckDeckGo by night | Organizer of the Ionic and IndieHackers Zürich Meetup

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store