title: Function that returns javascript SQL array
body: <p>I want to create a function that returns an SQL array but I can't seem to return the array.</p>
  <pre><code>function Infos (item) {
  bdddata.query(&quot;select * from table WHERE id = &quot;+ item +&quot;&quot;, function (error3, table, fields) { 
  if (error3) throw error3;
  
  return table;
  })}
  </code></pre>
  <p>console.log(Infos(&quot;1&quot;));</p>
  <p>Can anyone help me, thanks in advance.</p>