title: Firebase orderByChild and equalTo() queries don't work
body: <p>I'm developing an Android app with the following Firebase database table:</p>
  
  <pre><code>"posts": {
  "id_1": {
    "author": "google:111527135678918251124",
    "color": -2960686,
    "creationTime": 1427104145195,
    "text": "my text",
    "title": "my Title",
    "type": 0,
    "visible": true
  },
  "id_2": {
    "author": "google:111527135678918251524",
    "color": -2960686,
    "creationTime": 1427104145195,
    "text": "my text",
    "title": "my Title",
    "type": 2,
    "visible": true
   },
  "id_3": {
    "author": "google:111527135678918251124",
    "color": -2960686,
    "creationTime": 1427104145195,
    "text": "my text",
    "title": "my Title",
    "type": 1,
    "visible": true
   }
  }
  </code></pre>
  
  <p>I'd like to be able to retrieve a the posts sorted by a child (sorted by type as an example) and be able to retrieve all the posts with a specific child value (type = 1).
  Reading the Firebase docs it seems I have to write the following code, but I don't get the wanted result.</p>
  
  <p>Order by type</p>
  
  <pre><code>rootRef.child("posts").orderByChild("type")
              .addListenerForSingleValueEvent(new ValueEventListener() {
  
          @Override
          public void onDataChange(DataSnapshot dataSnapshot) {
              result = (HashMap&lt;String, Post&gt;) dataSnapshot.getValue();
          }
  
          @Override
          public void onCancelled(FirebaseError firebaseError) {
  
          }
      });
  </code></pre>
  
  <p>I get: an unordered Map of Posts</p>
  
  <p>Type = value</p>
  
  <pre><code>rootRef.child("posts").orderByChild("type").equalTo(1, "type").addListenerForSingleValueEvent(new ValueEventListener() {
          @Override
          public void onDataChange(DataSnapshot dataSnapshot) {
              result = dataSnapshot.getValue();
              result = result;
          }
  
          @Override
          public void onCancelled(FirebaseError firebaseError) {
  
          }
      })
  </code></pre>
  
  <p>I get: <code>null</code>.
  My <code>Datasnapshot</code> object has <code>key = "posts"</code> and <code>value = null</code></p>