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

Home -> Community -> Usenet -> c.d.o.misc -> sql loader size constraint in oracle 8

sql loader size constraint in oracle 8

From: Alex Landsman <landsman_at_esped.com>
Date: Mon, 14 Feb 2005 19:13:03 -0500
Message-ID: <42113e20$0$6370$9a6e19ea@unlimited.newshosting.com>


I'm trying to move a delimited file into a table. One of the fields in my table is set to varchar(4000), however the input is sometimes longer than 4000.
 I'd like to truncate the field to 4000 characters.  My control file looks like this;
  TRUNCATE
      INTO TABLE MYTABLE FIELDS TERMINATED BY "," optionally enclosed by '"'
trailing nullcols

(
BIGFIELD CHAR(4000) "substr(:BIGFIELD,1,4000)" )

This does not work. In fact doing a substr on anything over 255 chars does not seem to work even when you specify the size. The error looks like this; Rejected - Error on table MYTABLE, column BIGFIELD, Field in data file exceeds maximum length

I've seen this question put forth a few times using a google search, but it never seems to get answered, so any help here would be very appreciated. Received on Mon Feb 14 2005 - 18:13:03 CST

Original text of this message

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