Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我需要创建一个从另一个函数输出整数的函数:
select schema.next_rowid('schema', 'table');
该next_rowid()函数始终输出一个整数。使用 PostgreSQL 9。
next_rowid()
您是否阅读过有关如何定义函数的文档?
CREATE FUNCTION my_pretty_function() RETURNS int AS $$ SELECT schema.next_rowid('schema', 'table'); $$ LANGUAGE 'sql';