Re: date format not recognized

From: Peter Nilsson <airia_at_acay.com.au>
Date: Thu, 23 Oct 2008 14:25:08 -0700 (PDT)
Message-ID: <ffe90ca8-10fc-48e5-9839-98def8eb04eb@g25g2000prf.googlegroups.com>


muhammaddzulkarn..._at_gmail.com wrote:
> Peter Nilsson <ai..._at_acay.com.au> wrote:
> > muhammaddzulkarn..._at_gmail.com wrote:
> > > select hostname, to_char(to_date(&date_start ,
> > > 'YYYYMMDD' || to_date(&date_end, 'YYYYMMDD')), 'YYYY')
> > > from gen_api_performance_daily where statistics_date
> > > between to_date(&date_start, 'YYYYMMDD') and
> > > to_date(&date_end , 'YYYYMMDD')
> >
> > ...it's pretty obvious why you're getting the error...
> >
> >   to_char
> >   (
> >     to_date
> >     (
> >       &date_start,
> >       'YYYYMMDD' || to_date(&date_end, 'YYYYMMDD')
> >     ),
> >     'YYYY'
> >   )
> >
> > What do you think that || will produce?

>

> it was wrong to put || in date function.. my objective
> actually is to combine &date_start and &date_end into
> date function.

'Combine' in what way? Please show some actual examples; what you start with and what you're hoping to produce.

> i do not know to do it

Well we're at an impass. You know the inputs and outputs but not how to do the implementation. I probably know the implementation but I don't have the inputs and outputs. ;)

--
Peter
Received on Thu Oct 23 2008 - 16:25:08 CDT

Original text of this message