Default order of select datname from pg_database

From: Elías David <elias(dot)moreno(dot)tec(at)gmail(dot)com>
To: pgsql-admin <pgsql-admin(at)postgresql(dot)org>
Subject: Default order of select datname from pg_database
Date: 2014-04-19 07:19:14
Message-ID: CANNE3r1gyetpfiU_FWRtozD=cif7cphdWgz8RzPYYk-mKTrfVg@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-admin

Hi all,

By any change, does the following query have an "order by" by default when
omitted?:

select datname from pg_database;

I know you could pass and ORDER BY datname or similar but what I don't know
is if by default there's some kind of sort when the order by is omitted.

I executed that query against one of my servers and while looking at the
names it seems complety random, the order is always the same, for instance:

web2
template0
asdf
basic
postgres
web3
.....

Does anybody know?

Thanks in advance!

--
Elías David.

Responses

Browse pgsql-admin by date

  From Date Subject
Next Message Jason Mathis 2014-04-19 14:45:50 Re: Default order of select datname from pg_database
Previous Message Bruce Momjian 2014-04-19 02:24:47 Re: Difference between fsync and open_sync