title: Retrieve value from Database using cypress
body: <p>Can anyone help me with the below scenario?</p>
  
  <p>I have to execute a <code>select</code> statement and store the the result of the query in a variable using Cypress.</p>
  
  <p>Below is the code I tried. I want to store the result of the query </p>
  
  <p><code>select id from invoices where INumber = '.invoiceNumber.'</code> to variable <code>rec</code>.</p>
  
  <p>Please help me to achive this.</p>
  
  <pre class="lang-js prettyprint-override"><code>cy.task('sqlServer:execute',"select id from invoices where INumber = '.invoiceNumber.'")
  .then(function (recordset) {
      var rec = recordset
  })
  </code></pre>