Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.server -> Re: date - import
I have this problem sometimes as well (raw data may contain months and/or
days without the leading zero).
I load the data into a temporary table with the desired "date" field defined
as varchar2(....).
After loading the data, I run a user-defined function which I call fix_date() which deals with this problem.
Insert into final_table
select fix_date(textual_date), ....other fields
from temp_table
Here, we view "raw"data to be "bad" data until we have validated/cleansed/checked/purified/etc it, so all "incoming" data is always loaded into a temporary table first.
Andreas Lommel <him_lommel_at_t-online.de> wrote in message
news:38294b62.9257070_at_news.btx.dtag.de...
> Hi there, I want to import a date with SQL-Loader. The value is
> 00.00.0000, which stand for a standard date.
> Then there is a error message ORA-01847
> day of month must be between 1 and last day of month
> Cause: The day of the month listed in a date is invalid for the
> specified month. The day of the month (DD) must be between 1 and the
> number of days in that month.
> What can I do ???
>
Received on Thu Nov 11 1999 - 16:32:37 CST