RE: [SQL] Function and trigger problem

Поиск
Список
Период
Сортировка
От Michael J Davis
Тема RE: [SQL] Function and trigger problem
Дата
Msg-id 93C04F1F5173D211A27900105AA8FCFC145511@lambic.prevuenet.com
обсуждение исходный текст
Список pgsql-sql
Trigger functions must return OPAQUE (OLD or NEW).

-----Original Message-----From:    Adam H. Pendleton [SMTP:apendleton@vgsinc.com]Sent:    Tuesday, May 18, 1999 10:25
AMTo:   pgsql-sql@hub.orgSubject:    [SQL] Function and trigger problem
 
I use the following code to create a function:
create function employee_stats_update() returns int4 as 'insert into employee_stats values (  new.employee_name);
select1 as ignore_this'language 'plpgsql';
 

Then I create the following trigger:
create trigger update_employee_stats before insert on employee_master for each row  execute procedure
employee_stats_update();
This is what I get back when I try to create the trigger:
ERROR:  CreateTrigger: function employee_stats_update () does not
exist
Adam


В списке pgsql-sql по дате отправления:

Предыдущее
От: "Adam H. Pendleton"
Дата:
Сообщение: Function and trigger problem
Следующее
От: "Adam H. Pendleton"
Дата:
Сообщение: Re: [SQL] Function and trigger problem