]> granicus.if.org Git - postgresql/commit
postgres_fdw: When sending ORDER BY, always include NULLS FIRST/LAST.
authorRobert Haas <rhaas@postgresql.org>
Fri, 4 Mar 2016 16:35:46 +0000 (11:35 -0500)
committerRobert Haas <rhaas@postgresql.org>
Fri, 4 Mar 2016 16:37:42 +0000 (11:37 -0500)
commit3bea3f88d5fc3517042ba83d2906979256da2442
tree37520f014243fb01ab65adfc3aaaab957519b6d4
parent52fe6f4e02f89f6230994988af9abc23b332b83e
postgres_fdw: When sending ORDER BY, always include NULLS FIRST/LAST.

Previously, we included NULLS FIRST when appropriate but relied on the
default behavior to be NULLS LAST.  This is, however, not true for a
sort in descending order and seems like a fragile assumption anyway.

Report by Rajkumar Raghuwanshi.  Patch by Ashutosh Bapat.  Review
comments from Michael Paquier and Tom Lane.
contrib/postgres_fdw/deparse.c
contrib/postgres_fdw/expected/postgres_fdw.out
contrib/postgres_fdw/sql/postgres_fdw.sql