<html><div style='background-color:'><DIV class=RTE>Hi, </DIV>
<DIV class=RTE> </DIV>
<DIV class=RTE> I have been trying to figure out why this simple query doesn't execute if no record exist ! </DIV>
<DIV class=RTE> </DIV>
<DIV class=RTE>CREATE OR REPLACE FUNCTION del_rest() RETURNS TRIGGER AS '<BR>DECLARE<BR>    t record;<BR>  BEGIN<BR>      SELECT * INTO t FROM del2 WHERE (d2=OLD.d2 or old.d2 is null) and (d3=OLD.d3 or  old.d2 is null);<BR>         IF NOT FOUND THEN<BR>           RAISE NOTICE ''No such record exits in table del2'';<BR>         END IF;<BR>          return null;   <BR>   END;<BR>'LANGUAGE 'plpgsql';</DIV>
<DIV class=RTE> </DIV>
<DIV class=RTE>Looking forward for suggestions. Thanks</DIV>
<DIV class=RTE> </DIV>
<DIV class=RTE>Prasad.</DIV></div></html>