title: How to Parse JSON array in node js
body: <p>I was trying below code,where body is response from <code>HTTP GET</code>. When I tried to run it, I am getting below error.<br /></p>
  
  <blockquote>
    <p>Cannot read property '<code>po_number</code>' of undefined</p>
  </blockquote>
  
  <pre><code>{
      "d": {
          "results": [
              {
                  "po_number": "PO1001",
                  "product_id": "PD1001",
                  "message": "Exists",
                  "timestamp": "2016-05-01" 
              }
          ]
      }
  }
  </code></pre>
  
  <p>How to access <code>po_number</code></p>
  
  <pre><code>var profile = JSON.parse(body);
  console.log("profile: "+ profile.results.po_number);
  </code></pre>
  
  <p>I am getting <code>undefined</code> when i access above code</p>