Re: varchar to date

From: Harri Kaukovuo <harri.kaukovuo4_at_nic.fi>
Date: 28 Nov 2001 03:45:15 GMT
Message-ID: <9u1mkb$dfm$1_at_news1.song.fi>


longinus <longinus_at_zeus.polsl.gliwice.pl> wrote in news:3C040C2A.36EC3B0B_at_zeus.polsl.gliwice.pl:

> Date is stored in 'VARCHAR' field.
> SQL> select min(end_date)
>
> brings:
>
> MIN(END_DA
> ----------
> 15.10.2001
>
> I want to convert end_date (VARCHAR) for date and choose the oldest
> one..
> SQL> select min(to_date(end_date,'DD.MM.YYYY'))
> reached';
> ERROR:
> ORA-01839: date not valid for month specified
>
> What is wrong?????

Apparently your end_date column values do not fit the DD.MM.YYYY date format. Check your data, fix the incorrect dates and try again.

  • Harri
    [Quoted] Anti-spam: To reply by e-mail please ERASE the "4" after kaukovuo4
Received on Wed Nov 28 2001 - 04:45:15 CET

Original text of this message