Skip to content

Commit 26fd82d

Browse files
committed
psql: Mark table headers in \drds output for translation
1 parent 97ec962 commit 26fd82d

File tree

1 file changed

+7
-4
lines changed

1 file changed

+7
-4
lines changed

src/bin/psql/describe.c

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2522,16 +2522,19 @@ listDbRoleSettings(const char *pattern, const char *pattern2)
25222522
{
25232523
bool havewhere;
25242524

2525-
printfPQExpBuffer(&buf, "SELECT rolname AS role, datname AS database,\n"
2526-
"pg_catalog.array_to_string(setconfig, E'\\n') AS settings\n"
2525+
printfPQExpBuffer(&buf, "SELECT rolname AS \"%s\", datname AS \"%s\",\n"
2526+
"pg_catalog.array_to_string(setconfig, E'\\n') AS \"%s\"\n"
25272527
"FROM pg_db_role_setting AS s\n"
25282528
"LEFT JOIN pg_database ON pg_database.oid = setdatabase\n"
2529-
"LEFT JOIN pg_roles ON pg_roles.oid = setrole\n");
2529+
"LEFT JOIN pg_roles ON pg_roles.oid = setrole\n",
2530+
gettext_noop("Role"),
2531+
gettext_noop("Database"),
2532+
gettext_noop("Settings"));
25302533
havewhere = processSQLNamePattern(pset.db, &buf, pattern, false, false,
25312534
NULL, "pg_roles.rolname", NULL, NULL);
25322535
processSQLNamePattern(pset.db, &buf, pattern2, havewhere, false,
25332536
NULL, "pg_database.datname", NULL, NULL);
2534-
appendPQExpBufferStr(&buf, "ORDER BY role, database;");
2537+
appendPQExpBufferStr(&buf, "ORDER BY 1, 2;");
25352538
}
25362539
else
25372540
{

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy