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: ORA-01830 On Delete but not on Select?

Re: ORA-01830 On Delete but not on Select?

From: Anurag Varma <avoracle_at_gmail.com>
Date: 22 Mar 2007 14:36:42 -0700
Message-ID: <1174599402.805030.203220@o5g2000hsb.googlegroups.com>


On Mar 22, 5:00 pm, "Jens Mohrmann" <jmohrm..._at_snafu.de> wrote:
> Hello everyone,
>
> I wonder if someone can shed some light on this.
> I have a table where the date is stored as a varchar2. The column is called
> datetime.
>
> If I want to select all records more than 30 days ago with the following
> SQL, it works with no problem:
>
> SELECT * FROM MFLOGBOOK WHERE TO_DATE(TRIM(DATETIME), 'DD.MM.YYYY
> HH24:MI:SS')+30 < TO_DATE('22.03.2007', 'DD.MM.YYYY')
>
> However, if I want to delete them with
>
> DELETE FROM MFLOGBOOK WHERE TO_DATE(TRIM(DATETIME), 'DD.MM.YYYY
> HH24:MI:SS')+30 < TO_DATE('22.03.2007', 'DD.MM.YYYY')
>
> I get a
>
> ORA-01830: date format picture ends before converting entire input string
>
> The Database is Oracle 10g (10.2.0.1)
>
> Any help is being appreciated
>
> Jens Mohrmann

Are there any triggers on that table which might be causing this? Anurag Received on Thu Mar 22 2007 - 16:36:42 CDT

Original text of this message

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