2008/10/3, Antonio Prado <[EMAIL PROTECTED]>: > Por favor, o que pode estar errado na criação da Function e Trigger > abaixo? > > > CREATE FUNCTION teste(integer) RETURNS trigger AS > 'DELETE FROM cliente WHERE cliente_id=$1;' > LANGUAGE plpgsql; > >>> Query returned successfully with no result in 81 ms. > > > > CREATE TRIGGER teste BEFORE DELETE ON cliente_20080902 > FOR EACH ROW EXECUTE PROCEDURE teste(cliente_id); > >>> ERROR: function teste() does not exist >
A função utilizada em um gatilho não pode ter argumentos. Veja: http://www.postgresql.org/docs/8.3/interactive/plpgsql-trigger.html Osvaldo _______________________________________________ pgbr-geral mailing list [email protected] https://listas.postgresql.org.br/cgi-bin/mailman/listinfo/pgbr-geral
