Greetings.

I was trying to understand what - if any - are the guarantees with regards
to ordering for combining queries (UNION/UNION ALL/...). From this
message[1], it seems that UNION ALL does preserve the ordering of the
operand queries, whereas UNION does not (presumably neither do INTERSECT,
INTERSECT ALL, EXCEPT and EXCEPT ALL).

The documentation[2] makes no mention of this, I'd suggest adding a note
clarifying this.

Thanks,

Shay

[1] https://www.postgresql.org/message-id/26825.1064858...@sss.pgh.pa.us
[2] https://www.postgresql.org/docs/current/queries-union.html

Reply via email to