Bruce Momjian wrote:
> > Yeah, I agree. And I do think that there is also some value of having
> > constants for SECS_PER_MINUTE and MINUTES_PER_HOUR, because otherwise
> > it can be unclear what 60 means in a particular context. We're at
> > the high end of what I consider reasonable in terms of defining
> > constants to represent values that aren't likely to change, but there
> > is tangible value in being able to grep for those constants when
> > you're trying to figure out what things might need changing, or just
> > to understand the code better.
>
> Yes, I did have to study the code to figure out which to use:
>
> if (type == TZ || type == DTZ)
> {
> tz = -(val * MINS_PER_HOUR);
> result = dt2local(timestamp, tz);
> }
>
> We measure timezone differences in minutes.
Let me also add that I realize I am often a royal pain in the neck.
There is no smiley on that --- I know I am often chaotic in how I
approach things and push them forward. I do my best, but that is often
the outcome.
-- Bruce Momjian <bruce@momjian.us> http://momjian.us EnterpriseDB
http://enterprisedb.com
+ It's impossible for everything to be true. +