title: Getting error "Unknown column 'text' in 'field list'"
body: <p>I am trying to insert text to my database table <code>reqviews</code>. But I get the error message: </p>
  
  <p><code>Unknown column 'text' in 'field list'</code>. I'm not sure what's wrong with my code. Please help</p>
  
  <pre><code>if (isset($_POST['combut'])) {
      $rqvcom = $_POST['rqvcom'];
      $rqid = (int)$_GET['rqid'];
      $conn-&gt;query("
          INSERT INTO reqviews (rqvrqid, rqvuserid, rqvcom, rqvdate)
              SELECT {$rqid}, {$sid}, {$rqvcom}, NOW()
              FROM requests
              WHERE EXISTS (
                  SELECT rqid
                  FROM requests
                  WHERE rqid = {$rqid})
              AND NOT EXISTS (
                  SELECT rqvid
                  FROM reqviews
                  WHERE rqvuserid = {$sid}
                  AND rqvrqid = {$rqid})
              LIMIT 1
      ");
  }
  </code></pre>
  
  <p>What my code does: When some text is typed into <code>rqvcom</code> textarea, that text gets iserted to <code>rqvcom</code> column on <code>reqviews</code> table. If a row already exists on <code>reqviews</code> table with a <code>rqvuserid</code> user, then another row with that same userid cannot be inserted. My problem is my code gives me the error message I provided. </p>
  
  <p>Edit: Table <code>reqviews</code></p>
  
  <pre><code>rqvid | rqvrqid | rqvuserid | rqvcom | rqvdate
  </code></pre>
  
  <p>Table <code>requests</code></p>
  
  <pre><code>rqid
  </code></pre>