firebase - 使用 where 条件索引的 firestore 读取计数

标签 firebase indexing google-cloud-firestore price

这个问题在这里已经有了答案:





Firestore Pricing - Does The Amount Of Documents In A Collection Matters?

(1 个回答)


3年前关闭。




firestore 文档定价没有提到使用 where 条件读取索引数据。

如果我们有一个包含 100K 文档的集合(发票),其中包含(日期、数字、金额)等字段

我做了一个查询 get().where('date' , '==', 20180404')
这会计算 100K 还是只返回文档?

谢谢

最佳答案

查询使用索引,它们不会读取每个单独的文档。您将根据返回的文档数量而不是集合的大小收取费用。

另见 Todd's answer here ,我实际上会将您的问题标记为重复。

关于firebase - 使用 where 条件索引的 firestore 读取计数,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/49742717/

相关文章:

go - 前往Firestore获取收藏中的所有文档

swift - Firebase 计划推送通知

javascript - Uncaught ReferenceError : db is not defined

android - 如何将多个 Auth Provider 链接到 Android 上的 Firebase 帐户?

firebase - 如何更新 FirebaseRecyclerAdapter 的查询

python - 如何对数据集表中的列索引进行标签编码?

php - 打破 Wordpress post 循环并继续它

使用 'now' 的 Firebase 安全时间规则

Firebase 函数从 get 请求返回 400

flash - h264 mp4 索引到前端命令行