Fix order_by clause on new union queries

Thank god for PostgreSQL and its error messages.