Results 1 to 2 of 2
  1. #1
    Join Date
    May 2003
    Posts
    34

    Unanswered: external table problem

    Hi All

    Currently we are using external tables. The code is like this

    create table external_table
    (EMPNO NUMBER(4) ,
    ENAME VARCHAR2(10),
    JOB VARCHAR2(9),
    MGR NUMBER(4),
    HIREDATE DATE,
    SAL NUMBER(7, 2),
    COMM NUMBER(7, 2),
    DEPTNO NUMBER(2)
    )
    ORGANIZATION EXTERNAL
    ( type oracle_loader
    default directory data_dir
    access parameters
    ( fields terminated by ',' )
    location ('emp.dat')
    )

    So this will take a comma as a field terminator. But in some rare cases i am also getting teh data with commas causing the initial load to fail.

    How do i take care of such a scenario

    bye

  2. #2
    Join Date
    Aug 2003
    Location
    Where the Surf Meets the Turf @Del Mar, CA
    Posts
    7,776
    Provided Answers: 1
    >How do i take care of such a scenario
    Get rid of the extraneous commas before Oracle attaches to the file.
    You can lead some folks to knowledge, but you can not make them think.
    The average person thinks he's above average!
    For most folks, they don't know, what they don't know.
    Good judgement comes from experience. Experience comes from bad judgement.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •