I'm having a really hard time understanding how Nosql works so I hope someone can help me understand it a bit better.
I'm trying to make a simple chat application (One to one chat support and chat groups) and want to dislay a list of all the conversations that the current user is in. This is my table for it.
I tried getting the data in several ways. But what I currently have is this (Which should work according to the internet, but doesn't).
_membersRef.equalTo(1508, key: '1508').once().then((DataSnapshot snap) {
print(snap.value);
});
I also tried
_membersRef.startAt(1508).endAt(1508).once().then((DataSnapshot snap) {
print(snap.value);
});
What I want my code to do is return all records that have my account_id in them (1508 in this case). So it should return the record "one".
So if I change the uid in the code to 1509 it should return "One" and "two". How can I make this happen?