Welcome to ShenZhenJia Knowledge Sharing Community for programmer and developer-Open, Learning and Share
menu search
person
Welcome To Ask or Share your Answers For Others

Categories

i am getting the below error message while using the functionality of external table in oracle.

ORA-29913: error in executing ODCIEXTTABLEOPEN callout
ORA-29400: data cartridge error
KUP-00554: error encountered while parsing access parameters
KUP-01005: syntax error: found "field": expecting one of: "badfile,
byteordermark, characterset, column, data, delimited, discardfile,
disable_directory_link_check, fields, fixed, load, logfile, language,
nodiscardfile, nobadfile, nologfile, date_cache, preprocessor, readsize,
string, skip, territory, variable"

Actually, I have created a table by using below command

CREATE TABLE SUMIT (
NAME VARCHAR2(20),
AGE INTEGER)
ORGANIZATION EXTERNAL ( TYPE ORACLE_LOADER DEFAULT DIRECTORY TEST_FILES ACCESS PARAMETERS (RECORDS DELIMITED BY NEWLINE
FIELD TERMINATED BY ',') LOCATION ('feed.txt'));

and table was created successfully. when i am trying to view the contents of the table then i am getting the error. Directory object TEST_FILES is also correct. I have checked path as well as file name feed.txt. Below is the structure of feed.txt

sumit,123

I am using Linux environment. Please help me to resolve this issue.

See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
thumb_up_alt 0 like thumb_down_alt 0 dislike
182 views
Welcome To Ask or Share your Answers For Others

1 Answer

As shown in all the examples, and in the SQL*Loader documentation, and in the error message you quoted, it is fields not field:

CREATE TABLE SUMIT (
  NAME VARCHAR2(20),
  AGE INTEGER
)
ORGANIZATION EXTERNAL (
  TYPE ORACLE_LOADER DEFAULT DIRECTORY TEST_FILES ACCESS PARAMETERS (
    RECORDS DELIMITED BY NEWLINE
    FIELDS TERMINATED BY ','
  )
  LOCATION ('feed.txt')
);

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
thumb_up_alt 0 like thumb_down_alt 0 dislike
Welcome to ShenZhenJia Knowledge Sharing Community for programmer and developer-Open, Learning and Share
...