Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Mailing Lists -> Oracle-L -> Ang: RE: Sqlloader

Ang: RE: Sqlloader

From: <Roland.Skoldblom_at_ica.se>
Date: Tue, 13 Nov 2001 08:12:37 -0800
Message-ID: <F001.003C3581.20011113072021@fatcity.com>

Why does this sqlloader ctl file giveme this errormessage?

the control file looks like:

load data
infile 'c:\kam\kampanj.txt'
TRUNCATE
into table kampanjtyp_kopia
FIELDS TERMINATED BY ';'
 (KAMPANJTYP_ID "DECODE(:KAMPANJTYP_ID,'?','98'!','97', :KAMPANJTYP_ID)", KAMPANJTYP_NAMN) SQL*Loader-944: error preparing insert statement for table KAMPANJTYP_KOPIA. ORA-01756: quoted string not properly terminated

Thanks in advance

Roland S

"Mercadante, Thomas F" <NDATFM_at_labor.state.ny.us>@fatcity.com den 2001-11-13 05:10 PST

Sänd svar till ORACLE-L_at_fatcity.com

Sänt av: root_at_fatcity.com

Till: Multiple recipients of list ORACLE-L <ORACLE-L_at_fatcity.com> Kopia:

Hi Roland,

Try using the DECODE statement rather than TRANSLATE:

BUT_OMS "DECODE(:BUT_OMS, '!','99','?','No Info',:BUT_OMS)",

The above says:

If the value of BUT_OMS='!', change it to '99', elsif the value of BUT_OMS='?', change it to 'No Info', else

      insert the value provided.

Hope this helps

Tom Mercadante
Oracle Certified Professional

-----Original Message-----

Sent: Tuesday, November 13, 2001 3:00 AM To: Multiple recipients of list ORACLE-L

Hallo all you DBA's

How do I write in sqlloader if i want to replace, translate the caracter ? with 'No info' and the character ! with the value '99'. I have this statement already.

BUT_OMS "TRANSLATE(:BUT_OMS, '!','99')", Thanks in advance

Roland S

--

Please see the official ORACLE-L FAQ: http://www.orafaq.com
--

Author:
  INET: Roland.Skoldblom_at_ica.se

Fat City Network Services    -- (858) 538-5051  FAX: (858) 538-5051
San Diego, California        -- Public Internet access / Mailing Lists

--------------------------------------------------------------------
To REMOVE yourself from this mailing list, send an E-Mail message
to: ListGuru_at_fatcity.com (note EXACT spelling of 'ListGuru') and in the message BODY, include a line containing: UNSUB ORACLE-L (or the name of mailing list you want to be removed from). You may also send the HELP command for other information (like subscribing).
--

Please see the official ORACLE-L FAQ: http://www.orafaq.com
--

Author: Mercadante, Thomas F
  INET: NDATFM_at_labor.state.ny.us
Fat City Network Services    -- (858) 538-5051  FAX: (858) 538-5051
San Diego, California        -- Public Internet access / Mailing Lists

--------------------------------------------------------------------
To REMOVE yourself from this mailing list, send an E-Mail message
to: ListGuru_at_fatcity.com (note EXACT spelling of 'ListGuru') and in the message BODY, include a line containing: UNSUB ORACLE-L (or the name of mailing list you want to be removed from). You may also send the HELP command for other information (like subscribing).

--

Please see the official ORACLE-L FAQ: http://www.orafaq.com
--

Author:
  INET: Roland.Skoldblom_at_ica.se

Fat City Network Services    -- (858) 538-5051  FAX: (858) 538-5051
San Diego, California        -- Public Internet access / Mailing Lists

--------------------------------------------------------------------
To REMOVE yourself from this mailing list, send an E-Mail message
to: ListGuru_at_fatcity.com (note EXACT spelling of 'ListGuru') and in the message BODY, include a line containing: UNSUB ORACLE-L (or the name of mailing list you want to be removed from). You may also send the HELP command for other information (like subscribing). Received on Tue Nov 13 2001 - 10:12:37 CST

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US