Support RETURN QUERY for PL/PgSQL (#644)
Backport from upstream and related commits are commit e5fe2e84 Author: Tom Lane <tgl@sss.pgh.pa.us> Date: Fri Nov 9 23:58:32 2007 +0000 Recognize RETURN QUERY via a textual test, so that QUERY doesn't need to be a plpgsql keyword. This avoids springing a new reserved word on plpgsql programmers. For consistency, handle RETURN NEXT the same way. commit b2b9b4d5 Author: Neil Conway <neilc@samurai.com> Date: Wed Jul 25 04:19:09 2007 +0000 Implement RETURN QUERY for PL/PgSQL. This provides some convenient syntax sugar for PL/PgSQL set-returning functions that want to return the result of evaluating a query; it should also be more efficient than repeated RETURN NEXT statements. Based on an earlier patch from Pavel Stehule. Committers: Kuien Liu and Haozhou Wang
Showing
想要评论请 注册 或 登录