title: Comparing data of specific node with parallel data
body: <p>If my database looks like this:</p>
  
  <pre><code>database
     |_______id1
     |        |_______dataKey1: dataValue1
     |        |_______dataKey2: dataValue2
     |
     |_______id2
     |        |_______dataKey1: dataValue3
     |        |_______dataKey2: dataValue4
     |
     |_______id3
              |_______dataKey1: dataValue5
              |_______dataKey2: dataValue6
  </code></pre>
  
  <p>Assuming I am currently working with the user with <code>id1</code>, and I want to compare each <code>dataValue1</code> and <code>dataValue2</code> with the rest of the datas, ie <code>dataValue3</code>, <code>dataValue4</code>,<code>dataValue5</code> and <code>dataValue6</code> (assume they are integers for example). </p>
  
  <p>Right now I can simply get <code>dataValue1</code> and <code>dataValue2</code> using simple callback with a listener and <code>onDataChange</code>. I save these values in an ArrayList. So far everything is OK. But how to compare the data saved in the ArrayList with the rest of the data? I thought about looping through the ArrayList, and for each data in the ArrayList create another async callback to fetch the rest of the data. But it will make some nested async callbacks, and also call to the rest of the data many times (the amount of the values that the current user has) and I guess it's not the correct way to do that? It's something that should be easy to do, but with all that async callbacks I get stuck</p>