Re: Bug in psql - Mailing list pgsql-bugs

From Greg Sabino Mullane
Subject Re: Bug in psql
Date
Msg-id CAKAnmmLhdpFYc9kJF5ShazmNLChzFyzyk2YrhWbZ6mxudsaR4g@mail.gmail.com
Whole thread Raw
In response to Re: Bug in psql  (Chris BSomething <xpusostomos@gmail.com>)
Responses Re: Bug in psql
List pgsql-bugs
My patch was just committed by Tom (who did most of the work, thank you Tom!). So now you should see much less of "List of relations" in future versions of psql (which is backwards compatible!)

About your changes:

-       /* If tabtypes is empty, we default to \dtvmsE (but see also command.c) */
+       /* If tabtypes is empty, we default to \dtivmsE (but see also command.c) */

This was not an oversight: \d defaults to all types EXCEPT indexes, on purpose.

+               if (showViews) {
+                       if (cntTitle != 0) {
+                               strcat(title, ", ");
+                       }
+                       strcat(title, "views");
+                       cntTitle++;
+               }
...

See discussion on my patch about why we cannot do this for translation reasons. Well, we can do it, but we'd be asking the translators to either handle around 64 new strings, or to forcibly accept some assumptions about how their language should work.

-       HELP0("  \\dE[Sx+] [PATTERN]     list foreign tables\n");
+       HELP0("  \\dew[x+] [PATTERN]     list foreign-data wrappers\n");
        HELP0("  \\des[x+] [PATTERN]     list foreign servers\n");
-       HELP0("  \\det[x+] [PATTERN]     list foreign tables\n");
+       HELP0("  \\dE[Sx+] [PATTERN]     list foreign tables (basic info)\n");
+       HELP0("  \\det[x+] [PATTERN]     list foreign tables (foreign info)\n");
        HELP0("  \\deu[x+] [PATTERN]     list user mappings\n");
-       HELP0("  \\dew[x+] [PATTERN]     list foreign-data wrappers\n");

I like this part, it's definitely an improvement. 

Cheers,
Greg

--
Crunchy Data - https://www.crunchydata.com
Enterprise Postgres Software Products & Tech Support


pgsql-bugs by date:

Previous
From: Tom Lane
Date:
Subject: Re: BUG #18795: Norwegian bokmål crashes again
Next
From: PG Bug reporting form
Date:
Subject: BUG #18796: Npgsql Driver: Foreign Key Read Inversion in INSERT Operations