Function won't compile

Поиск
Список
Период
Сортировка
От Joop van Bussel
Тема Function won't compile
Дата
Msg-id 3bd6c319$0$28889$4d4ebb8e@read-nat.news.nl.uu.net
обсуждение исходный текст
Ответы Re: Function won't compile  (Stephan Szabo <sszabo@megazone23.bigpanda.com>)
Re: Function won't compile  ("Dr. Evil" <drevil@sidereal.kz>)
Re: Function won't compile  ("Aasmund Midttun Godal" <postgresql@envisity.com>)
Список pgsql-general
Hi,

Does anybody know why the function insert_case() won't compile. When I
INSERT a new record I always get the following error message :

NOTICE:  plpgsql: ERROR during compile of insert_case near line 1
"RROR:  parse error at or near "

Below is the function and trigger. ('Now' is surrounded with single quotes)

CREATE FUNCTION insert_case () RETURNS INTEGER AS '
  BEGIN
    NEW.date_created := ''now'';
  END;
' LANGUAGE 'SQL';

CREATE TRIGGER trg_insert_case BEFORE INSERT ON pfdcase FOR EACH ROW EXECUTE
PROCEDURE insert_case();


Thanks



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

Предыдущее
От: Bruce Momjian
Дата:
Сообщение: Re: index files still growing
Следующее
От: Peter Pilsl
Дата:
Сообщение: variables in functions ..