Re: SQl Loader 305 Error
Date: 2000/06/30
Message-ID: <slqes4j0op397_at_corp.supernews.com>#1/1
<kasthuri_at_viisage.com> wrote in message news:8jie90$c7k$1_at_nnrp1.deja.com...
> Hi All,
>
> I have an amt column in my table which is NUMBER(11,2). The input data
> contains a trailing negative sign and doesnt contain decimal points. i
> have something like this in my control file. But i get an error saying
> that the token is longer than allowable 258 char. I dont know how i can
> further reduce it. Is there any other way of doing it?
> Any suggestions would help.
>
> Control file:
>
> contrib_amt POSITION(21:35) DECIMAL EXTERNAL "decode
> (substr(:contrib_amt,length(:contrib_amt)),'-',-to_number(substr
> (:contrib_amt,1,length(:contrib_amt)-3)||'.'||substr(:contrib_amt,length
> (:contrib_amt)-3,2)),to_number(
> substr(:contrib_amt,1,length(:contrib_amt)-3)||'.'||substr
> (:contrib_amt,length(:contrib_amt)-3,2)))"
>
> - I tried with Zoned also. it didnt work. gave me an 'invalid zoned
> decimal nibble'
It's your decode statement I think. SQL*Loader likes these things (functions that you perform on the data) to be 256 characters or less. No way around it that I know of (directly). One option is to load into a temporary table as-is and then do a insert w/embedded select and you perform your decode as part of the select from within SQL*Plus.
-Matt Received on Fri Jun 30 2000 - 00:00:00 CEST