Tema: Trigger
Ver Mensaje Individual
  #5 (permalink)  
Antiguo 17/01/2007, 02:22
seanchan
 
Fecha de Ingreso: junio-2006
Mensajes: 87
Antigüedad: 17 años, 10 meses
Puntos: 0
Re: Trigger

Prueba con algo asi:

SELECT 1
INTO VEXISTE
FROM SINTONIA
WHERE SINTONIA.codigo=:NEW.USO_SINTONIA;

EXCEPTION

WHEN no_data_found then
insert into SINTONIA(codigo) values (:new.uso_sintonia);
END;

En la select no utilices la tabla sobre la que va el trigger porque te dará error de tabla mutante