Results 1 to 3 of 3
  1. #1
    Join Date
    May 2002
    Posts
    62

    Question Unanswered: SQL Loader question

    Hi All,

    I am using the following control file to load data into an oracle table (version 8.1.4).

    LOAD DATA
    APPEND
    INTO TABLE FF_DA_TAPER_TERM
    FIELDS TERMINATED BY '|'
    TRAILING NULLCOLS
    ( WIRE_CNTR_CD,
    WIRE_CNTR_NAME,
    TAPER_CD "SUBSTR(:taper_cd,1,6)",
    SERVING_TRML_NAME,
    SERVING_TRML_FUNCTION,
    DA_CD,
    LOOP_MEDIUM_TYPE,
    CSA_NAME,
    CSA_LENGTH,
    SERVING_TRML_TYPE)

    But I am getting the following error when I run the script.
    SQL*Loader-417: SQL string (on column TAPER_CD) not allowed in direct path.

    Can some one please help me what I am doing wrong here.
    How else I can achieve this task using SQL Loader only ?

    Thanx..
    -Bheemsen

  2. #2
    Join Date
    Sep 2002
    Location
    UK
    Posts
    5,171
    Provided Answers: 1

    Re: SQL Loader question

    The error message is pretty clear. You are trying to run SQL Loader in direct path mode, and your control file includes the SQL string "SUBSTR(:taper_cd,1,6)". Not allowed.

    Possible solutions:
    1) Don't use direct path
    2) Use direct path, take off the SUBSTR and load into a temporary table. Then copy the data from the temporary table to the real table using SUBSTR.

    Since the whole point of using direct path is to spued up the load, option (2) looks pointless (nice fast load, followed by not so fast insert), so I suggest you go for option (1) - unless of course you are already using a temporary table.

  3. #3
    Join Date
    May 2002
    Posts
    62

    Thanx for the response

    andrewst ,

    Thanx for your response. I am going with conventional method and it works.

    -Bheemsen

Posting Permissions

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