quotes nightmare!

Поиск
Список
Период
Сортировка
От Graham Vickrage
Тема quotes nightmare!
Дата
Msg-id NDBBJABDILOPAOOMFJHOGECGDEAA.graham@digitalplanit.com
обсуждение исходный текст
Ответы Re: quotes nightmare!  (Stephan Szabo <sszabo@megazone23.bigpanda.com>)
Re: quotes nightmare!  (Roberto Mello <rmello@cc.usu.edu>)
Список pgsql-sql
I am having trouble with my quotes in a function and think I have tried
every comb (obviously not) as it does not work:

I am trying to create a function within a function passing the second
function into the first as a parameter as follows:-

CREATE FUNCTION _test(text) RETURNS int AS '
BEGINEXECUTE ''CREATE FUNCTION _test'' || $1 || '' () RETURNS int AS ''BEGIN    RAISE EXCEPTION ''Help'';RETURN
2;END'';LANGUAGE ''plpgsql'' '';
 
RETURN 1;
END;'
LANGUAGE 'plpgsql';

SELECT _test('ing');

Could anyone tell me which bit is causing the problem as I am now completely
lost, the error message mentions is near LANGUAGE.

Many thanks

Graham.





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

Предыдущее
От: "Christopher Kings-Lynne"
Дата:
Сообщение: Re: Can someone help me with this function?
Следующее
От: Richard Emberson
Дата:
Сообщение: Finding matching columns from two tables