Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.misc -> Re: date question
<vijay_dwi_at_yahoo.com> wrote in message
news:1151895143.858830.240330_at_m79g2000cwm.googlegroups.com...
> Hi,
>
> I have a string in the format ('MM/DD/YYYY)
> examples('12/12/2006') or ('2/12/2006') or ('12/1/2006') or
> ('1/1/2006') .
> Have to to take the date and lpad it with ZERO if its a single digit.
>
> Can you please let me know the sql ?
>
> thanks.
>
Dates are dates and dates are not strings. You can format a date to a
string representation.
to_char(sysdate,'mm/dd/yyyy')
or character to date to_date('2/12/2006','mm/dd/yyyy')
Jim Received on Sun Jul 02 2006 - 22:26:24 CDT
![]() |
![]() |