Re: sql insert function

Поиск
Список
Период
Сортировка
От Chris Ochs
Тема Re: sql insert function
Дата
Msg-id 024e01c3d96c$5bdef6a0$250a8b0a@chris
обсуждение исходный текст
Ответ на sql insert function  ("Chris Ochs" <chris@paymentonline.com>)
Ответы Re: sql insert function  (Alex Satrapa <alex@lintelsys.com.au>)
Список pgsql-general
Never mind, I forgot to quote the quote's...

Chris

> The documentation doesn't have any examples of using an sql language
> function to do an insert, andI am at loss as to I am doing wrong here.
> The error I get trying to create the function is:  ERROR:  syntax error at
> or near "$1" at character 148
>
> CREATE FUNCTION taxship(varchar,integer,varchar,float,float) returns
integer
> AS '
> insert into taxship(s_oid,order_id,mer_id,tax,shipping) values
> ('$1',$2,'$3',$4,$5);
> SELECT 1;
> ' LANGUAGE SQL;
>
>
> ---------------------------(end of broadcast)---------------------------
> TIP 7: don't forget to increase your free space map settings
>


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

Предыдущее
От: "Chris Ochs"
Дата:
Сообщение: sql insert function
Следующее
От: Alex Satrapa
Дата:
Сообщение: Re: sql insert function