Bruno Wolff III wrote:
On Fri, Jul 22, 2005 at 12:27:50 -0700,
Dann Corbit <[EMAIL PROTECTED]> wrote:
Apparently, the Gregorian calendar has been fixed. From this:
http://www.physics.uq.edu.au/people/ross/phys2081/time/calendar.htm
We have this:
"The Gregorian calendar has been modified
On 2005-07-22, Bruce Momjian wrote:
> Bruno Wolff III wrote:
>> According to the current calendar (again ignoring leap seconds) there
>> are exactly 365.2425 days per year on average. I think it makes sense to use
>> this number when dealing with calendar years and months.
>
> Someone came up with
On Fri, Jul 22, 2005 at 12:27:50 -0700,
Dann Corbit <[EMAIL PROTECTED]> wrote:
> Apparently, the Gregorian calendar has been fixed. From this:
> http://www.physics.uq.edu.au/people/ross/phys2081/time/calendar.htm
>
> We have this:
> "The Gregorian calendar has been modified since (before anythi
age-
> From: Bruce Momjian [mailto:[EMAIL PROTECTED]
> Sent: Friday, July 22, 2005 12:03 PM
> To: Bruno Wolff III
> Cc: Dann Corbit; Greg Stark; Tino Wildenhain; Tom Lane; PostgreSQL-
> development; Marc G. Fournier
> Subject: Re: [HACKERS] Imprecision of DAYS_PER_MONTH
>
2, 2005 12:24 PM
> To: 'Bruce Momjian'; Bruno Wolff III
> Cc: Greg Stark; Tino Wildenhain; Tom Lane; PostgreSQL-development;
Marc G.
> Fournier
> Subject: RE: [HACKERS] Imprecision of DAYS_PER_MONTH
>
> 365.2425 is the exact value computed by the formulas found in the
&
Bruno Wolff III wrote:
> On Thu, Jul 21, 2005 at 13:47:29 -0700,
> Dann Corbit <[EMAIL PROTECTED]> wrote:
> > In round figures:
> >
> > Since there are 365.2422 days per tropical year, there are 31556926
> > seconds per year (give or take leap seconds).
> >
> > Ref:
> > http://www.grc.nasa.gov/
On Thu, Jul 21, 2005 at 13:47:29 -0700,
Dann Corbit <[EMAIL PROTECTED]> wrote:
> In round figures:
>
> Since there are 365.2422 days per tropical year, there are 31556926
> seconds per year (give or take leap seconds).
>
> Ref:
> http://www.grc.nasa.gov/WWW/K-12/Numbers/Math/Mathematical_Thinki
in; Tom Lane; PostgreSQL-development; Marc G.
> Fournier
> > Subject: Re: [HACKERS] Imprecision of DAYS_PER_MONTH
> >
> > Greg Stark wrote:
> > >
> > > Bruce Momjian writes:
> > >
> > > > > > BTW, if you actually wanted to improve rea
Bruno Wolff III wrote:
Shouldn't you be using 365.2425/12 (30.436875) for the number of days per
month?
Well, ISO 8601 prefers "30" to some weird fraction when they
define the term "month"; and uses a different term "calendar
month" for the exact number of days in a known month.
They make a
Greg Stark wrote:
>
> Bruce Momjian writes:
>
> > > > BTW, if you actually wanted to improve readability, defining a
> > > > SECS_PER_YEAR value and replacing the various occurrences of
> > > > "36525 * 864" with it would help.
> > > >
> > > IIRC the number of seconds in a year is far from a co
nal Message-
> From: [EMAIL PROTECTED] [mailto:pgsql-hackers-
> [EMAIL PROTECTED] On Behalf Of Bruce Momjian
> Sent: Thursday, July 21, 2005 1:35 PM
> To: Greg Stark
> Cc: Tino Wildenhain; Tom Lane; PostgreSQL-development; Marc G.
Fournier
> Subject: Re: [HACKERS] Imprecis
Bruce Momjian writes:
> > > BTW, if you actually wanted to improve readability, defining a
> > > SECS_PER_YEAR value and replacing the various occurrences of
> > > "36525 * 864" with it would help.
> > >
> > IIRC the number of seconds in a year is far from a constant.
>
> Yes, I added a commen
Tom Lane wrote:
> Another problem with this patch is the search-and-replace substitution
> of "SECS_PER_MINUTE" for "60", when in point of fact there are two
> different meanings of "60" in this context. For instance, this
> code has no problem:
>
> ! int Log_RotationAge = 24 * 60
Tino Wildenhain wrote:
> Am Donnerstag, den 21.07.2005, 10:48 -0400 schrieb Tom Lane:
> > Another problem with this patch is the search-and-replace substitution
> > of "SECS_PER_MINUTE" for "60", when in point of fact there are two
> > different meanings of "60" in this context. For instance, this
Bruno Wolff III wrote:
> On Thu, Jul 21, 2005 at 09:39:38 -0400,
> Bruce Momjian wrote:
> >
> > I have added this comment above the DAYS_PER_MONTH macro:
> >
> > + /*
> > + *DAYS_PER_MONTH is very imprecise. The more accurate value is
> > + *365.25/12 = 30.4375, or '30 d
Am Donnerstag, den 21.07.2005, 10:48 -0400 schrieb Tom Lane:
> Another problem with this patch is the search-and-replace substitution
> of "SECS_PER_MINUTE" for "60", when in point of fact there are two
> different meanings of "60" in this context. For instance, this
> code has no problem:
>
> !
Another problem with this patch is the search-and-replace substitution
of "SECS_PER_MINUTE" for "60", when in point of fact there are two
different meanings of "60" in this context. For instance, this
code has no problem:
! int Log_RotationAge = 24 * 60;
but this code looks lik
Bruno Wolff III <[EMAIL PROTECTED]> writes:
> On Thu, Jul 21, 2005 at 09:39:38 -0400,
> Bruce Momjian wrote:
>> Let me add that we could actually do this in many places now because we
>> are already converting to 'time' in those places. Is this a TODO?
> Shouldn't you be using 365.2425/12 (30.
On Thu, Jul 21, 2005 at 09:39:38 -0400,
Bruce Momjian wrote:
>
> I have added this comment above the DAYS_PER_MONTH macro:
>
> + /*
> + *DAYS_PER_MONTH is very imprecise. The more accurate value is
> + *365.25/12 = 30.4375, or '30 days 10:30:00'. Right now we only
19 matches
Mail list logo