title: Subquery in a Trigger at ORACLE
body: <p>Hi i want to do a subquery in a trigger</p>
  
  <p>like this:</p>
  
  <pre><code>CREATE OR REPLACE TRIGGER verificar_edad
  
  BEFORE INSERT ON reserva
  
  FOR EACH ROW
  
  DECLARE
  
  BEGIN
  
  IF (:new.pasaporte_cliente in (SELECT pasaporte FROM cliente WHERE fecha_nacimiento&gt;'1996/01/01')) THEN
  
        DBMS_OUTPUT.PUT_LINE ('El cliente debe ser mayor de edad');
  
   END IF;
  
  END;
  </code></pre>
  
  <p>/</p>
  
  <p>but it does not works... What am I supposed to do?</p>
  
  <p>Thanks.</p>