Re: Invalid date with SQLLOAD

From: Leon Gommans <gommans_at_iso.few.eur.nl>
Date: Tue, 6 Dec 1994 12:33:42 GMT
Message-ID: <gommans.41.2EE45A26_at_iso.few.eur.nl>


In article <3bgqoe$c7q_at_news.cais.com> sarek_at_cais2.cais.com (Scott T Johnson) writes:
>From: sarek_at_cais2.cais.com (Scott T Johnson)
>Subject: Invalid date with SQLLOAD
>Date: 30 Nov 1994 03:15:25 GMT
 

>I have a LARGE datafile to load which contains dates. Some of the data
>are dates but they are invalid. If the date is invalid, SQL*Load rejects
>the entire record. Is there a way to place a NULL in the appropriate
> field if the date is invalid?
> Thanks,
> Scott

In the files I had to load in i had blank records (spaces) or all zeros ('000000'). If the problem with dates is equivalent with mine problem you can solve the problem the following way. (The only problem is you can solve only a maximum of 2 disctinct date-errors (as far as I know))

TheDate         position (xx:yy) DATE "YYMMDD" NULLIF(TheDate = '000000') 
                                          DEFAULTIF (TheDate = '      '))


Leon

Gommans_at_iso.few.eur.nl Received on Tue Dec 06 1994 - 13:33:42 CET

Original text of this message