pg.ddx.io pgsql-docs@postgresql.org mailing list archive
help / color / mirror / Atom feedTable 9.31. to_char Examples
3+ messages / 3 participants
[nested] [flat]
* Table 9.31. to_char Examples
@ 2026-09-28 14:26 PG Doc comments form <noreply@postgresql.org>
2026-09-28 19:05 ` Re: Table 9.31. to_char Examples David G. Johnston <david.g.johnston@gmail.com>
0 siblings, 1 reply; 3+ messages in thread
From: PG Doc comments form @ 2026-09-28 14:26 UTC (permalink / raw)
To: pgsql-docs@lists.postgresql.org; +Cc: y.saburov@gmail.com
The following documentation comment has been logged on the website:
Page: https://www.postgresql.org/docs/18/functions-matching.html
Description:
This is not true:
```html
to_char(485, 'PL999') '+485'
```
add examples:
```psql
db=# SELECT quote_literal(to_char(timestamp '2026-04-15','RM'));
quote_literal
---------------
'IV '
(1 рядок)
db=# SELECT quote_literal(to_char(timestamp '2026-04-15','FMRM'));
quote_literal
---------------
'IV'
(1 рядок)
db=# SELECT quote_literal(to_char(timestamp '2026-12-31', 'rm'));
quote_literal
---------------
'xii '
(1 рядок)
```
^ permalink raw reply [nested|flat] 3+ messages in thread
* Re: Table 9.31. to_char Examples
2026-09-28 14:26 Table 9.31. to_char Examples PG Doc comments form <noreply@postgresql.org>
@ 2026-09-28 19:05 ` David G. Johnston <david.g.johnston@gmail.com>
2026-09-29 12:55 ` Re: Table 9.31. to_char Examples Daniel Gustafsson <daniel@yesql.se>
0 siblings, 1 reply; 3+ messages in thread
From: David G. Johnston @ 2026-09-28 19:05 UTC (permalink / raw)
To: y.saburov@gmail.com <y.saburov@gmail.com>; pgsql-docs@lists.postgresql.org <pgsql-docs@lists.postgresql.org>
On Monday, September 28, 2026, PG Doc comments form <noreply@postgresql.org>
wrote:
> The following documentation comment has been logged on the website:
>
> Page: https://www.postgresql.org/docs/18/functions-matching.html
> Description:
>
> This is not true:
>
> ```html
> to_char(485, 'PL999') '+485'
> ```
>
You are correct. As a practical matter there will always be a space after
the plus sign since the formatting code seems to consumes two places. This
may arguably be a bug, but at this point we should just document the
behavior we have.
David J.
^ permalink raw reply [nested|flat] 3+ messages in thread
* Re: Table 9.31. to_char Examples
2026-09-28 14:26 Table 9.31. to_char Examples PG Doc comments form <noreply@postgresql.org>
2026-09-28 19:05 ` Re: Table 9.31. to_char Examples David G. Johnston <david.g.johnston@gmail.com>
@ 2026-09-29 12:55 ` Daniel Gustafsson <daniel@yesql.se>
0 siblings, 0 replies; 3+ messages in thread
From: Daniel Gustafsson @ 2026-09-29 12:55 UTC (permalink / raw)
To: David G. Johnston <david.g.johnston@gmail.com>; +Cc: y.saburov@gmail.com <y.saburov@gmail.com>; pgsql-docs@lists.postgresql.org <pgsql-docs@lists.postgresql.org>
> On 28 Sep 2026, at 21:05, David G. Johnston <david.g.johnston@gmail.com> wrote:
> This may arguably be a bug, but at this point we should just document the
> behavior we have.
Agreed, pushed and backpatched all the way. The documentation has this output
down to 7.1 but I only tested down to 14.
--
Daniel Gustafsson
^ permalink raw reply [nested|flat] 3+ messages in thread
end of thread, other threads:[~2026-09-29 12:55 UTC | newest]
Thread overview: 3+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2026-09-28 14:26 Table 9.31. to_char Examples PG Doc comments form <noreply@postgresql.org>
2026-09-28 19:05 ` David G. Johnston <david.g.johnston@gmail.com>
2026-09-29 12:55 ` Daniel Gustafsson <daniel@yesql.se>
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox