Is it possible to have a CHECK under the form:
CREATE TABLE abc (no INTEGER, det INTEGER NOT NULL,
quo INTEGER CHECK (quo < AVG(st.quo)),
qoh INTEGER CHECK (qoh >= 0));
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?