title: SQL check when creating a table
body: <p>Is it possible to have a CHECK under the form: </p>
  
  <pre><code>CREATE TABLE abc (no INTEGER, det INTEGER NOT NULL,
  quo INTEGER CHECK (quo &lt; AVG(st.quo)),
  qoh INTEGER CHECK (qoh &gt;= 0));
  </code></pre>
  
  <p>So basically every time new values are entered to check the average of quo of another (existing) table  in the database and if and only if it's lower than the average of that table to allow new data to be inserted in the table? </p>