Re: Error in creating function

Поиск
Список
Период
Сортировка
От A. Kretschmer
Тема Re: Error in creating function
Дата
Msg-id 20071206132505.GC15524@a-kretschmer.de
обсуждение исходный текст
Ответ на Error in creating function  (Yancho <mpulis@gmail.com>)
Список pgsql-general
am  Thu, dem 06.12.2007, um  4:16:14 -0800 mailte Yancho folgendes:
> I am trying to create a function, which takes the nearest 3 hospitals
> to a point making use of a PostGIS function), and then check each
> hospital for the exact distance on roads (by making use of a pgRouting
> function).
>
> Below please find a copy of my function, and u can also find it
> highlighted here : http://yancho.pastebin.com/f13cc045e
>
> CREATE OR REPLACE FUNCTION near_hospital(text, integer, integer)
>   RETURNS integer AS
> $BODY$
> ...
> END;
>
> ' language 'plpgsql';
>
>
> The error being given by pgAdminIII is : unterminated dollar-quoted
> string at or near "$BODY$" [then some garbled text] for $1;
>
> Any help will be extremely appreciated!

change the last line into:

$BODY$ language 'plpgsql';




Regards, Andreas
--
Andreas Kretschmer
Kontakt:  Heynitz: 035242/47150,   D1: 0160/7141639 (mehr: -> Header)
GnuPG-ID:   0x3FFF606C, privat 0x7F4584DA   http://wwwkeys.de.pgp.net

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

Предыдущее
От: "A. Kretschmer"
Дата:
Сообщение: Re: how to redirect output to a file
Следующее
От: Cedric Boudin
Дата:
Сообщение: Re: simple update on boolean