[英]How to query realtime database with AngularFire?
how to check a specific data in realtime database as well as it checks in firestore ?如何检查实时数据库中的特定数据以及它在 firestore 中的检查?
this.afs.collection('collection', ref => ref.where('data', "==", date
)).snapshotChanges(.subscribe(res => {
I've try我试过了
this.database.list('collection', ref => ref.where
but, "Property 'where' does not exist on type 'Reference'."但是,“属性 'where' 在类型 'Reference' 上不存在。”
我建议查看有关在实时数据库中查询列表的 AngularFire 文档,以及有关在 JavaScript 中排序和过滤实时数据库数据的 Firebase 文档,这些文档表明查询是通过以下方式完成的:
this.database.list('collection', ref => ref.orderByChild("data").equalTo(date))
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.