Move the options column of \db+ before the description
authorMagnus Hagander
Sun, 26 Jan 2014 20:13:57 +0000 (21:13 +0100)
committerMagnus Hagander
Sun, 26 Jan 2014 20:16:02 +0000 (21:16 +0100)
The convention is to have the description field at the end.

Noted by Tom Lane

src/bin/psql/describe.c

index 43f1a1c12dd2dd7f829733b6f08aefaf377633b1..3cb8df2bb72fc63ea8e63bb29785725fb310431f 100644 (file)
@@ -171,16 +171,16 @@ describeTablespaces(const char *pattern, bool verbose)
        printACLColumn(&buf, "spcacl");
    }
 
-   if (verbose && pset.sversion >= 80200)
-       appendPQExpBuffer(&buf,
-        ",\n  pg_catalog.shobj_description(oid, 'pg_tablespace') AS \"%s\"",
-                         gettext_noop("Description"));
-
    if (verbose && pset.sversion >= 90000)
        appendPQExpBuffer(&buf,
                          ",\n  spcoptions AS \"%s\"",
                          gettext_noop("Options"));
 
+   if (verbose && pset.sversion >= 80200)
+       appendPQExpBuffer(&buf,
+        ",\n  pg_catalog.shobj_description(oid, 'pg_tablespace') AS \"%s\"",
+                         gettext_noop("Description"));
+
    appendPQExpBufferStr(&buf,
                         "\nFROM pg_catalog.pg_tablespace\n");