我有一堆我想要索引的键 .indexOn
假设我的数据如下所示.我希望能够使用.orderByChild("height").
{
"lambeosaurus": {
"stats": {
"height" : 2.1,
"length" : 12.5,
"weight": 5000
}
},
"stegosaurus": {
"stats": {
"height" : 4,
"length" : 9,
"weight" : 2500
}
}
}
Run Code Online (Sandbox Code Playgroud)
伤口我如何指定索引的规则是height哪个stats?我是否需要对数据进行重组或展平?