Code review for pushing LIMIT through subqueries. Minor improvements for commit 1f6d515a6. We do not need the (rather expensive) test for SRFs in the targetlist, because since v10 any such SRFs would appear in separate ProjectSet nodes. Also, make the code look more like the existing cases by turning it into a simple recursion --- the argument that there might be some performance benefit to contorting the code seems unfounded to me, especially since any good compiler should turn the tail-recursion into iteration anyway.
Discussion: http://postgr.es/m/cade5jyluugneeusyw6q_4mzfytxhxavcqmgasf0yiy8zdgg...@mail.gmail.com Branch ------ master Details ------- https://git.postgresql.org/pg/commitdiff/3f4c7917b3bc8b421c0c85cb9995974c55e7232b Modified Files -------------- src/backend/executor/nodeLimit.c | 58 +++++++++++++++++++++------------------- 1 file changed, 30 insertions(+), 28 deletions(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers