Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.misc -> Re: Week numbers and days

Re: Week numbers and days

From: Scott Mattes <Scott_at_TheMattesFamily.ws>
Date: Fri, 07 Feb 2003 14:42:16 GMT
Message-ID: <cBP0a.3643$jR3.1697133@news1.news.adelphia.net>


I get the following when week = 01

    1 select next_day(to_date(substr('200301',1,4),'yyyy')+   2* to_number(substr('200301',5,2)-7),'WEDNESDAY') from dual SQL> / NEXT_DAY(



29-JAN-03 "Guido Konsolke" <Guido.Konsolke_at_triaton.com> wrote in message news:1044619922.598866_at_news.thyssen.com...
> "Valery V. Tsekhmister" wrote...
> > Hi Chris !
> >
> > It's only one pill needed to perform such a conversion:
> >
> > select next_day(
> > to_date(substr('200306',1,4),'YYYY')+
> > (substr('200306',5,2)-1)*7
> > ,'WEDNESDAY') from dual
> >
> >
> > Regards.
> >
> > Valery
>
> Hi Valery,
>
> not quite right, I think.
>
> Maybe:
>
> select next_day(to_date(substr('200306',1,4),'yyyy')+
> to_number(substr('200306',5,2)-7),'WEDNESDAY') from dual;
>
> will do it.
>
> Nice weekend to everyone,
> Guido
>
>
Received on Fri Feb 07 2003 - 08:42:16 CST

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US