Skip to Main Content

SQL & PL/SQL

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

convert varchar2(2) to interval

oraLaroJul 27 2016 — edited Jul 27 2016

I have an external table with data that I want to insert into a fixed table.   The fixed table has some interval datatypes.

One of the columns is defined as   INTERVAL DAY(1) TO SECOND(3)

data example is  '0 days 00:00:03.000000000'

 

My external table is all varchar and I have a view layered on the table so I need to convert that string to that interval type.  No matter what I do I get  ORA-01867: the interval is invalid

easiest way to replicate

select to_dsinterval('0 days 00:00:03.000000000') from dual

ORA-01867: the interval is invalid

Is it the data?

This post has been answered by CarlosDLG on Jul 27 2016
Jump to Answer
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Aug 24 2016
Added on Jul 27 2016
4 comments
515 views