Re: Change "two" to "three" for decades of development in history

Поиск
Список
Период
Сортировка
От Erik Wienhold
Тема Re: Change "two" to "three" for decades of development in history
Дата
Msg-id 221510448.1356631.1687483046344@office.mailbox.org
обсуждение исходный текст
Ответ на Re: Change "two" to "three" for decades of development in history  (Bruce Momjian <bruce@momjian.us>)
Ответы Re: Change "two" to "three" for decades of development in history  (Michael Paquier <michael@paquier.xyz>)
Список pgsql-docs
> On 22/06/2023 23:00 CEST Bruce Momjian <bruce@momjian.us> wrote:
>
> On Thu, Jun 22, 2023 at 01:47:16PM -0700, Kirk Parker wrote:
> >
> > I don't suppose DocBook has macro and system-variable capabilities? That
> > could provide a set-and-forget solution to this?
>
> Uh, I am not aware of any.

An SGML entity [0] or an xsltproc stringparam [1] looks viable.  Question is
how to calculate the number of decades in the Makefile.  It's trivial in SQL :)

    =# select extract(decade from now()) - extract(decade from date '1986-01-01');
     ?column?
    ----------
            4
    (1 row)
    
    =# select extract(day from now() - date '1986-01-01') / 365.25 / 10;
          ?column?
    --------------------
     3.7472963723477071
    (1 row)

[0]
https://git.postgresql.org/gitweb/?p=postgresql.git;a=blob;f=doc/src/sgml/Makefile;h=71cbef230f34a6ad6b41a667c7d2977fb6560378;hb=HEAD#l98
[1]
https://git.postgresql.org/gitweb/?p=postgresql.git;a=blob;f=doc/src/sgml/Makefile;h=71cbef230f34a6ad6b41a667c7d2977fb6560378;hb=HEAD#l56

--
Erik



В списке pgsql-docs по дате отправления:

Предыдущее
От: Bruce Momjian
Дата:
Сообщение: Re: Change "two" to "three" for decades of development in history
Следующее
От: Michael Paquier
Дата:
Сообщение: Re: Change "two" to "three" for decades of development in history