From: | Karel Zak <zakkr(at)zf(dot)jcu(dot)cz> |
---|---|
To: | Peter Eisentraut <peter_e(at)gmx(dot)net> |
Cc: | Don Baccus <dhogaza(at)pacifier(dot)com>, pgsql-hackers <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Re: day of week |
Date: | 2000-06-07 16:56:42 |
Message-ID: | Pine.LNX.3.96.1000607185035.3467K-100000@ara.zf.jcu.cz |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On Wed, 7 Jun 2000, Peter Eisentraut wrote:
> Karel Zak writes:
>
> > The Oracle always directly set first week on Jan-01, but day-of-week count
> > correct... It is pretty dirty, but it is a probably set in libc's mktime().
>
> The first week of the year is most certainly not (always) the week with
> Jan-01 in it. My understanding is that it's the first week where the
> Thursday is in the new year, but I might be mistaken. Here in Sweden much
> of the calendaring is done based on the week of the year concept, so I'm
> pretty sure that there's some sort of standard on this. And sure enough,
> this year started on a Saturday, but according to the calendars that hang
> around here the first week of the year started on the 3rd of January.
You probably right. I belive that Thomas say more about it...
> >
> > oracle's to_char:
> > * week-start is a sunday
> > * first week start on Jan-01, but day-of-week is count continual
> >
> > PG date_part/trunc:
> > * week-start in monday
> > * first week is a first full week in new year (really?)
>
> The worst thing we could do is having an inconsistency here. Having a
> configuration option or two that applies to both sounds better.
Yes, but Oracle "porters" need probably oracle pseudo
calculation..
For PG date_part/trunc will SET (or anything like this) good.
Karel
From | Date | Subject | |
---|---|---|---|
Next Message | Jeff MacDonald | 2000-06-07 18:57:22 | odbc |
Previous Message | Bruce Momjian | 2000-06-07 16:45:09 | Re: Look at heap_beginscan() |