How to query a list of Objects with Firebase in Flutter

前端 未结 1 1791
一向
一向 2021-01-27 08:25

I want to be able to query my collections for document Ids, and then get a list of documents. For Example: Collection [Users] -> Documents [001], [002], [003]. Now I want to qu

1条回答
  •  时光说笑
    2021-01-27 08:53

    You can use an in query for anywhere up to 10 documents.

    collectionRef.where("country", whereIn: ["USA", "Japan"])
    

    If you have more than 10, you can either load them in batches of 10, or so individual calls for each document.

    0 讨论(0)
提交回复
热议问题