Invalid query. You cannot use more than one 'in' filter

你离开我真会死。 提交于 2020-05-15 21:21:30

问题


this.ref.collection("users", ref => ref.where("uid1","in", [reciverId, senderId])
        .where("uid2","in", [reciverId, senderId]))

give me error like

"Invalid query. You cannot use more than one 'in' filter"


回答1:


This is indeed a limitation of Firestore, as explained in the documentation:

Limitations

Note the following limitations for in and array-contains-any:

  • in and array-contains-any support up to 10 comparison values.
  • You can use only one in or array-contains-any clause per query. You can't use both in and array-contains-any in the same query.
  • You can combine array-contains with in but not with array-contains-any.


来源:https://stackoverflow.com/questions/60474746/invalid-query-you-cannot-use-more-than-one-in-filter

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!