Here is the preview of the tree:
I tried to do this:
mRef.orderByChild("desc").equalTo(des).addChildEventListener(new ChildEventListener()
{
@Override
public void onChildAdded(DataSnapshot dataSnapshot, String s)
{
mRef.orderByChild("userid").equalTo(uid).addChildEventListener(new ChildEventListener() {
@Override
public void onChildAdded(DataSnapshot dataSnapshot, String s)
{
myParentNode = dataSnapshot.getKey();
}
});
});
But it returns the value of the previously visited node.
Note: The Parent node "ASSIST Blog" contains many children which may have similar values.