Problems w/ PL/pgSQL not being loaded?

Поиск
Список
Период
Сортировка
От Diehl, Jeffrey
Тема Problems w/ PL/pgSQL not being loaded?
Дата
Msg-id B51F0C636E578A4E832D3958690CD73E0130BEB2@es04snlnt
обсуждение исходный текст
Ответы Re: Problems w/ PL/pgSQL not being loaded?  (Philip Hallstrom <philip@adhesivemedia.com>)
Список pgsql-sql
Hi all.

Once again, I'm trying to climb the learning curve...

I'm trying to write a trigger in PL/pgSQL to update some tables.  When I try
to load the function, I get an error message:

The function is:

create function update_modified () returns opauqe as '       BEGIN               NEW.modified := ''now()'';
 return 1;       END;
 
'
language 'plpgsql';

The error message indicates that I'm trying to us an unrecognized language.
The recognized languages are sql, C, internal and other created languages.
I've not loaded anything besides the default.

1.  How do I load PL/pgSQL?

2.  Does this function look right?  It should change the a.modified field
upon update.

Thanx again,
Mike Diehl,
Network Monitoring Tool Devl.
284-3137
jdiehl@sandia.gov



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

Предыдущее
От: Oleg Bartunov
Дата:
Сообщение: Re: RTREE on points
Следующее
От: Philip Hallstrom
Дата:
Сообщение: Re: Problems w/ PL/pgSQL not being loaded?