title: jq error when looping through array: Cannot index array with string "<key>"
body: <p>I'm tryng to iterate over all element contain in the <code>all</code> index. Here is my json string : </p>
  
  <pre><code>{  
     "all":[  
        {  
              "id":"51a"
        },
        {  
              "id":"52b"
        },
        {  
              "id":"53c"
        }
      ]
  }
  </code></pre>
  
  <p>I have tried to iterate with <code>jq</code> :</p>
  
  <pre><code>for id in $(jq '.all.id | keys | .[]' &lt;&lt;&lt; "$json"); do
      echo "$id"
  done
  </code></pre>
  
  <p>But I get this following error :</p>
  
  <blockquote>
    <p>jq: error (at :9): Cannot index array with string "id"</p>
  </blockquote>
  
  <p>I expect to get the following output :</p>
  
  <pre><code>51a
  52b
  53c
  </code></pre>