mirror of
https://github.com/postgres/postgres.git
synced 2025-11-13 16:22:44 +03:00
In messages, use singular nouns for -1, like we do for +1.
This outputs "-1 year", not "-1 years". Reported-by: neverov.max@gmail.com Bug: 16939 Discussion: https://postgr.es/m/16939-cceeb03fb72736ee@postgresql.org
This commit is contained in:
@@ -303,7 +303,7 @@ PQprint(FILE *fout, const PGresult *res, const PQprintOpt *po)
|
||||
}
|
||||
if (po->header && !po->html3)
|
||||
fprintf(fout, "(%d row%s)\n\n", PQntuples(res),
|
||||
(PQntuples(res) == 1) ? "" : "s");
|
||||
(abs(PQntuples(res)) == 1) ? "" : "s");
|
||||
if (po->html3 && !po->expanded)
|
||||
fputs("</table>\n", fout);
|
||||
free(fieldMax);
|
||||
@@ -662,7 +662,7 @@ PQdisplayTuples(const PGresult *res,
|
||||
|
||||
if (!quiet)
|
||||
fprintf(fp, "\nQuery returned %d row%s.\n", PQntuples(res),
|
||||
(PQntuples(res) == 1) ? "" : "s");
|
||||
(abs(PQntuples(res)) == 1) ? "" : "s");
|
||||
|
||||
fflush(fp);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user