Question about creating functions

Поиск
Список
Период
Сортировка
От Robert Stachurski
Тема Question about creating functions
Дата
Msg-id Pine.BSF.4.21.0011211607360.56275-100000@home.altech.com.pl
обсуждение исходный текст
Список pgsql-general
I'm trying to write any function which returns chars or few columns from
table but it dosn't work.

This my sample function and it doesn't, work meybe somebody can help me
and
tell what I'm doing wrong.

CREATE FUNCTION one(int4) RETURNS int4 AS 'select id from s_url where
id_url=$1;' LANGUAGE 'sql'

id is int4 and primary key
id is int4

and second question:
did I in good way sending parameters to the function.


Maybe sombady have few sample function which could send me, or same manual
files(but other than that which are in pgman).
Thanks
Robert



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

Предыдущее
От: "Adam Lang"
Дата:
Сообщение: Re: I loose my history keys using psql...
Следующее
От: Tom Lane
Дата:
Сообщение: Re: [HACKERS] (download ANSI SQL benchmark?) Re: Postgres article