【发布时间】:2018-10-23 07:06:04
【问题描述】:
我想知道是否有一种方法可以在 Flutter 中查询 firebase firestore 集合,向查询中添加多个字段。我尝试了一些方法,但我没有意识到如何做到这一点。例如:
CollectionReference col = Firestore.instance
.collection("mycollection");
col.where('nome', isEqualTo: 'Tyg');
col.where('valor', isLessThan: '39');
有人,请有办法做到这一点?我是 Flutter 的新手,但没有找到方向。
【问题讨论】:
-
你试过
var query = col.where('nome', isEqualTo: 'Tyg').where('valor', isLessThan: '39');吗? -
嗯,我会试试这个方法,让你知道好不好。非常感谢您的回复。
标签: firebase dart google-cloud-firestore flutter