From: | Janus <janus(dot)e(at)gmail(dot)com> |
---|---|
To: | "pgadmin-support lists(dot)postgresql(dot)org" <pgadmin-support(at)lists(dot)postgresql(dot)org> |
Subject: | Default order on displaying data without order clause |
Date: | 2019-03-15 11:20:23 |
Message-ID: | CAJTmWxiEPk13Df75uVJgHaKB4rK4LrfzrxApE5tgO6-7dNA38g@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgadmin-support |
In pgAdmin 3, an implicit default order by primary key is used when
displaying data without an otherwise stated order. This is not the case in
pgAdmin 4. The order seems somewhat arbitrary and the following statement from
this <http://www.postgresqltutorial.com/postgresql-order-by/> site is
definitely not true: "*When you query data from a table, PostgreSQL returns
the rows in the order that they were inserted into the table.*"
I do understand that *some* order of course exists, but from a
human perspective it would make sense that default ordering is by PK,
unless stated otherwise. In PgAdmin 4, is it possible to set a default
ordering, at least so that displaying a table's contents using the "View
Data" button, i.e. the query being run is altered from "SELECT oid, * FROM
public.mytable" to "SELECT oid, * FROM public.mytable ORDER BY <primary
key(s)>"?
Thanks!
From | Date | Subject | |
---|---|---|---|
Next Message | Wim Bertels | 2019-03-15 12:15:34 | Re: Default order on displaying data without order clause |
Previous Message | Isaias Sanchez | 2019-03-14 12:21:22 | Re: Could you please advise how to set the csv download path? Thanks. |