Javascript 使用Firebase查询参数时;在;我得到;“操作员”;错误
我正在运行一个连接到Firebase的React本机应用程序,我正在尝试将where子句中的“==”替换为 “in”操作员: 而不是Javascript 使用Firebase查询参数时;在;我得到;“操作员”;错误,javascript,firebase,react-native,google-cloud-firestore,react-native-firebase,Javascript,Firebase,React Native,Google Cloud Firestore,React Native Firebase,我正在运行一个连接到Firebase的React本机应用程序,我正在尝试将where子句中的“==”替换为 “in”操作员: 而不是 firebase .firestore() .collection("Post") .where("authorID", "==", "John") 我把它变成:
firebase
.firestore()
.collection("Post")
.where("authorID", "==", "John")
我把它变成:
firebase
.firestore()
.collection("Post")
.where("authorID", "in", ["John", "Maria"])
我收到错误com.facebook.react.bridge.NoSuchKeyException运算符
我已经安装了中提到的库
我正在使用react native firebase
库版本5.6.0
此错误的来源是什么?似乎有一个额外的分号:
firebase.firestore().collection(“Post”);。其中(“authorID”、“in”、“John”、“Maria”)
。不应该是firebase.firestore().collection(“Post”)。where(“authorID”、“in”、“John”、“Maria”)
?@RenaudTarnec这只是一个问题输入错误。对不起,我找到了这份对你有帮助的文件。我还发现了解释此错误的原因。@MrTech我已经添加了问题中提到的库。似乎还有一个分号:firebase.firestore().collection(“Post”);。其中(“authorID”、“in”、“John”、“Maria”)
。不应该是firebase.firestore().collection(“Post”)。where(“authorID”、“in”、“John”、“Maria”)
?@RenaudTarnec这只是一个问题输入错误。对不起,我找到了这份对你有帮助的文件。我还发现了解释此错误的原因。@MrTech我已经添加了问题中提到的库。