PostgreSQL sequence within function

Поиск
Список
Период
Сортировка
От Clark Allan
Тема PostgreSQL sequence within function
Дата
Msg-id 4a7a732105063012037cf8dc1e@mail.gmail.com
обсуждение исходный текст
Ответы Re: PostgreSQL sequence within function  (Tony Caduto <tony_caduto@amsoftwaredesign.com>)
Список pgsql-general
I am new to Postgre, and am still learning some of the basics...
please bare with me.

I need to know how to access a sequence from within a function. Let me
know whats wrong with the following...

(this is not the exact function, just for examples sake...)
----------------------------------------------
CREATE FUNCTION getSeq()
RETURNS int AS'
RETURN nextval('myseq')
'LANGUAGE 'plpgsql';
----------------------------------------------

Thanks for the help
Clark

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

Предыдущее
От: "Adam O'Toole"
Дата:
Сообщение: get the SALT
Следующее
От: Albert Vernon Smith
Дата:
Сообщение: optimizer not optimizing