Home » RDBMS Server » Server Utilities » sqlloader error
sqlloader error [message #269836] Mon, 24 September 2007 16:07 Go to next message
lawlade
Messages: 59
Registered: May 2007
Location: LAUREL, MARYLAND
Member
Hello All -
I am trying to load data into a table using sql loader but everytime I try I get a "second enclosure string not present" error message. Can anyone help out?

I have created the following:

CREATE TABLE "SYSTEM"."ASBESTOS_FILE_LIST_LJ"
( "FILE_ID" NUMBER(10,0),
"FACILITY_ID" VARCHAR2(20 BYTE),
"AREA" VARCHAR2(20 BYTE),
"DISTRICT" VARCHAR2(50 BYTE),
"FACILITY_NAME" VARCHAR2(100 BYTE),
"ZIPCODE" VARCHAR2(10 BYTE),
"FILEPATH" VARCHAR2(300 BYTE),
"FILENAME" VARCHAR2(100 BYTE),
"FOLDER" VARCHAR2(200 BYTE),
"FILE_SIZE" VARCHAR2(10 BYTE),
"FILE_TYPE" VARCHAR2(100 BYTE),
"FILE_TITLE" VARCHAR2(100 BYTE);

create sequence lj_sequence
increment by 1
start with 1;

CREATE OR REPLACE TRIGGER system.lj_trigger
BEFORE INSERT
ON asbestos_file_list_lj
FOR EACH ROW
BEGIN
SELECT system.lj_sequence.nextval
INTO :NEW.file_id
FROM DUAL;
END;
/

Here's my controlfile script:

load data
infile *
REPLACE
INTO TABLE SYSTEM.ASBESTOS_FILE_LIST_LJ
FIELDS TERMINATED BY ',' OPTIONALLY ENCLOSED BY "" TRAILING NULLCOLS

(
FACILITY_ID CHAR,
AREA CHAR,
DISTRICT CHAR,
FACILITY_NAME CHAR ,
ZIPCODE INTEGER EXTERNAL,
FILEPATH CHAR,
FILENAME CHAR,
FOLDER CHAR,
FILE_SIZE INTEGER EXTERNAL,
FILE_TYPE CHAR,
FILE_TITLE CHAR,
FILE_ID "LJ_SEQUENCE.NEXTVAL"
)
begindata
1444110,,,,,c:\lola\whatever.doc,whatever.doc,c:\lola,Word Document,,
Re: sqlloader error [message #269841 is a reply to message #269836] Mon, 24 September 2007 17:33 Go to previous messageGo to next message
andrew again
Messages: 2577
Registered: March 2000
Senior Member
looks like SQLLDR thinks it's a BFILE.

SQL*Loader-00623 second enclosure string not present

Cause: The logical end of record or the end of a LOBFILE was reached before a second enclosure delimiter was found. 

Action: Correct the datafile to include the missing delimiter. 


http://www.orafaq.com/faq/how_does_one_use_sql_loader_to_load_images_sound_clips_and_documents

[Updated on: Mon, 24 September 2007 17:33]

Report message to a moderator

Re: sqlloader error [message #269854 is a reply to message #269836] Mon, 24 September 2007 20:31 Go to previous message
Barbara Boehmer
Messages: 9101
Registered: November 2002
Location: California, USA
Senior Member
If you are trying to optionally enclose by double quotes, then it needs to be optionally enclosed by '"'. That is one double quote surrounded by two single quotes. Use your sequence in a trigger or the control file, not both. There may be other errors.
Previous Topic: Calling stored Procedure from SQL*LOADER
Next Topic: SQL Loader: Filtering data
Goto Forum:
  


Current Time: Wed Dec 25 09:42:37 CST 2024