Re: control reaches end of trigger procedure without RETURN
| От | Jeff Eckermann |
|---|---|
| Тема | Re: control reaches end of trigger procedure without RETURN |
| Дата | |
| Msg-id | 20020807133524.20086.qmail@web20803.mail.yahoo.com обсуждение исходный текст |
| Ответ на | control reaches end of trigger procedure without RETURN (rramostalo@quorum.com) |
| Список | pgsql-sql |
The error says it. In this case, you need to add "return NEW;" before the "end;" --- rramostalo@quorum.com wrote: > > > create function duplicate_images() returns OPAQUE > as' > DECLARE > myrec RECORD; > BEGIN > if TG_OP = ''INSERT'' then > select * into myrec from images where > page=NEW.page and > path=NEW.path; > if found then > raise exception ''insert failed: > duplicate record found''; > end if; > end if; > end; > ' language 'plpgsql'; > > > > ---------------------------(end of > broadcast)--------------------------- > TIP 4: Don't 'kill -9' the postmaster __________________________________________________ Do You Yahoo!? Yahoo! Health - Feel better, live better http://health.yahoo.com
В списке pgsql-sql по дате отправления: