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

Home -> Community -> Mailing Lists -> Oracle-L -> RE: strip out characaters during sqlldr

RE: strip out characaters during sqlldr

From: David Moss <David.Moss_at_fdmgroup.com>
Date: Wed, 7 Mar 2007 10:54:11 -0000
Message-ID: <39132CDDC017F3459FFD0F26B3F8A09F2D2A9F@fdm-mail01.fdmgroup.local>


You just need to enclose an sql string function in double quotes (see example), obviously you will need replace or somesuch rather than what i've put there  

David.  

LOAD DATA
INFILE 'new_employees.csv'
INTO TABLE TEMP_EMP
FIELDS TERMINATED BY ','
TRAILING NULLCOLS
(

   LAST_NAME                        "decode(substr(:last_name, 0, 20),
'', null, substr(:last_name, 0, 20))"
 , TITLE                            CHAR NULLIF (TITLE=BLANKS)
...
)

From: oracle-l-bounce_at_freelists.org
[mailto:oracle-l-bounce_at_freelists.org] On Behalf Of John Dunn Sent: 07 March 2007 10:40
To: oracle-l
Subject: strip out characaters during sqlldr

I need to strip out all spaces from a string when loading data via sqlldr direct load.  

Is this possible? What would be the control file syntax?  

Needs to work in Oracle 8 and 9.        

John in transmission.    



This e-mail has been scanned for all viruses by Star. The service is powered by MessageLabs. For more information on a proactive anti-virus service working around the clock, around the globe, visit: http://www.star.net.uk

This message is from FDM Group Plc, and may contain information that is confidential or privileged. If you are not the intended recipient, please delete the message and any attachments and notify the sender. This email is not intended to create legally binding commitments on behalf of FDM Group Plc, nor do its contents reflect the corporate views or policies of FDM. Any unauthorised disclosure, use or dissemination, either whole or partial, is prohibited. FDM Group Plc is a private limited company registered in England (Reg. No. 2542980).



This e-mail has been scanned for all viruses by Star Internet. The service is powered by MessageLabs. For more information on a proactive anti-virus service working around the clock, around the globe, visit: http://www.star.net.uk
--
http://www.freelists.org/webpage/oracle-l
Received on Wed Mar 07 2007 - 04:54:11 CST

Original text of this message

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