Path: news.cambrium.nl!textnews.cambrium.nl!feeder1.cambriumusenet.nl!feed.tweaknews.nl!194.134.4.91.MISMATCH!news2.euro.net!newsgate.cistron.nl!newsgate.news.xs4all.nl!post.news.xs4all.nl!not-for-mail
Date: Thu, 09 Sep 2010 23:11:15 +0200
From: shakespeare <whatsin@xs4all.nl>
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; nl; rv:1.9.2.9) Gecko/20100825 Thunderbird/3.1.3
MIME-Version: 1.0
Newsgroups: comp.databases.oracle.server
Subject: Re: handling special characters in sqlldr
References: <a6b7e40b-b7dd-4b0e-a00f-ea7486fe68b6@j19g2000vbh.googlegroups.com>
In-Reply-To: <a6b7e40b-b7dd-4b0e-a00f-ea7486fe68b6@j19g2000vbh.googlegroups.com>
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
Content-Transfer-Encoding: 7bit
Lines: 46
Message-ID: <4c894d75$0$22938$e4fe514c@news.xs4all.nl>
NNTP-Posting-Host: 82.95.215.210
X-Trace: 1284066677 news.xs4all.nl 22938 [::ffff:82.95.215.210]:50403
X-Complaints-To: abuse@xs4all.nl
Xref:  news.cambrium.nl

Op 9-9-2010 18:11, dmardkar schreef:
> Hi,
>
> I am trying to load a record(s) in a table which contains a field of
> text datatype. The records in question contain occasional single
> qoutes. This is an example of such records:
>
> en|PRD-SHPE|11.0|NOTE:  If a slab is a dummy', an asterisk is
> displayed at the end of the|20011003.0|
>
>
> I am then creating a control file and use sqlldr to load the data but
> the load fails with the following messege:
>
>
> Record 1: Rejected - Error on table SCRHLP_REC, column HLP_TXT.
> ORA-12899: value too large for column
> "RPSNX31"."SCRHLP_REC"."HLP_TXT" (actual: 75, maximum: 74)
>
>
> Here is the control file I am using:
>
>
> load data
> infile "./scrhlp.dat" "str X'400A'"
> badfile "./scrhlp.bad"
> into table scrhlp_rec
> fields terminated by "|"
> (
> HLP_LNG_CD         ,
> HLP_FLD_NM         ,
> HLP_LN_NO          ,
> HLP_TXT ,
> HLP_REF_DT
> )
>
>
>
> If I remove the single qoute in the data, all works fine. How do I
> specify that a single qoute is acceptable in this case? Please help.
>
> Thanks.

Make the column some chars longer.

Shakespeare
