title: JSONPath: Get root array object using filter of child value
body: <p>Im trying to get JSONPath expression to filter my JSON and get whole sport object using value of child array.</p>
  <p>I have following JSON:</p>
  <pre><code>[{
  
          &quot;name&quot;: &quot;Soccer&quot;,
          &quot;regions&quot;: [{
                  &quot;name&quot;: &quot;Australia&quot;,
                  &quot;leagues&quot;: [{
                          &quot;name&quot;: &quot;Australia league&quot;,
                          &quot;inplay&quot;: 5,
                      }
                  ]
              }
          ]
      }, {
  
          &quot;name&quot;: &quot;Tennis&quot;,
          &quot;regions&quot;: [{
                  &quot;name&quot;: &quot;Germany&quot;,
                  &quot;leagues&quot;: [{
                          &quot;name&quot;: &quot;Germany league&quot;,
                          &quot;inplay&quot;: 0,
                      }
                  ]
              }
          ]
      }
  ]
  </code></pre>
  <p>I need to get whole sport object where &quot;inplay == 0&quot; using JsonPath expression.</p>
  <p>Result should look like that:</p>
  <pre><code> {
  
      &quot;name&quot;: &quot;Tennis&quot;,
      &quot;regions&quot;: [{
              &quot;name&quot;: &quot;Germany&quot;,
              &quot;leagues&quot;: [{
                      &quot;name&quot;: &quot;Germany league&quot;,
                      &quot;inplay&quot;: 0,
                  }
              ]
          }
      ]
  }
  </code></pre>
  <p>Regions and Leagues count can be &gt; 1
  Therefore <code>$[?(@.regions[0].leagues[0].inplay == 0)]</code> is not suitable</p>
  <p>Tried <code>$[?(@.regions[*].leagues[*].inplay == 0)]</code> but it doesnt work</p>