#1
  1. No Profile Picture
    Registered User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Sep 2003
    Posts
    29
    Rep Power
    0

    Return code (Success or Fail) of sqlldr


    Hi,

    I would like to know what will be the return code for the sql loader when there is rejection of single record from the data file.

    Can someone please tell me regarding return code of sqlldr so that depending on that i would be able to take some action.

    The other methods which are there to do the same :
    1) To scan the log file and check for rejected keyword
    2) To check weather any bad file is created.

    Any help would be highly appreciated.

    Thanks!!
  2. #2
  3. No Profile Picture
    Contributing User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Sep 2003
    Posts
    68
    Rep Power
    12
    I'm not aware of anything else besides the log file and the bad file. SQL*Loader, by nature, is a batch program, which is usually invoked by the operating system (i.e. cron job). So, it reports about its detections only via its own files.

    Cheers,
    Dan
  4. #3
  5. No Profile Picture
    Registered User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Sep 2003
    Posts
    29
    Rep Power
    0
    hi,

    Thanks for replying.
    I got few things from the web.

    Here are the exit codes return by the sqlldr for unix and windows nt respectively.

    Result Exit Code
    All rows loaded successfully
    EX_SUCC

    All or some rows rejected
    EX_WARN

    All or some rows discarded
    EX_WARN

    Discontinued load
    EX_WARN

    Command-line or syntax errors
    EX_FAIL

    Oracle errors nonrecoverable for SQL*Loader
    EX_FAIL

    Operating system errors (such as file open/close and malloc)
    EX_FTL



    For UNIX, the exit codes are as follows:

    EX_SUCC 0
    EX_FAIL 1
    EX_WARN 2
    EX_FTL 3


    For Windows NT, the exit codes are as follows:

    EX_SUCC 0
    EX_WARN 2
    EX_FAIL 3
    EX_FTL 4


    If SQL*Loader returns any exit code other than zero, you should consult your system log files and SQL*Loader log files for
    more detailed diagnostic information.

    I guess i would be able to do something with this.

    Anyway thanks for replying.

    Regards,
  6. #4
  7. No Profile Picture
    Registered User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Sep 2014
    Posts
    7
    Rep Power
    0
    hiii
    Return code of sqlldr is 0,1,2,3,127


    Any return code other than 0 is failure and 0 is success
    and 127 is syntax error or wrong command

IMN logo majestic logo threadwatch logo seochat tools logo