Results 1 to 2 of 2
  1. #1
    Join Date
    Jun 2004
    Location
    Liverpool, NY USA
    Posts
    2,509

    Unanswered: Problem with sqlldr.

    I have a problem and hope that someone can help me out.

    I am trying to use sqlldr on my pc to load into an 8i database table out on our sun server. Unfortunally, I don't usually use sqlldr. I am getting the following error when I run sqlldr on my PC. I want this to work on my PC, any ideas?
    -------------------------------
    C:\>cd pro-zip

    C:\pro-zip>sqlldr userid=schema/password@instance control=LOAD_MASTER_ZIP.CTL

    SQL*Loader: Release 8.1.7.0.0 - Production on Thu Oct 14 12:06:59 2004

    (c) Copyright 2000 Oracle Corporation. All rights reserved.

    SQL*Loader-925: Error while ulmtsyn: OCIStmtExecute(tabhp)
    ORA-01405: fetched column value is NULL

    C:\pro-zip>
    ---------------------------------

    Below is the control file
    ++++++++++++++++++++++++++++
    LOAD DATA
    INFILE 'PZDA.CSV'
    DISCARDFILE 'PZDA.DSC'
    REPLACE
    INTO TABLE MASTER_ZIP
    FIELDS TERMINATED BY "|"
    (ZIP_CD,
    ST_CD,
    CITY,
    COUNTY,
    CITY_SEQ,
    USPS_PRIM,
    AREA_CODE)
    ++++++++++++++++++++++++++++

    Below is the desctiption of the table
    SQL> DESC MASTER_ZIP
    Name Null? Type
    ----------------------------------------- -------- -----------------
    ZIP_CD NOT NULL VARCHAR2(5)
    CITY_SEQ NOT NULL NUMBER(2)
    ST_CD NOT NULL VARCHAR2(2)
    CITY NOT NULL VARCHAR2(30)
    COUNTY VARCHAR2(30)
    AREA_CODE NOT NULL VARCHAR2(3)
    USPS_PRIM NOT NULL VARCHAR2(1)

    SQL>

    Below is the first 10 lines of the PZDA.CSV file
    =================================
    00726|PR|Caguas|Caguas|1|P|787
    00727|PR|Caguas|Caguas|1|P|787
    00728|PR|Ponce|Ponce|1|P|787
    00729|PR|Canovanas|Canovanas|1|P|787
    00730|PR|Ponce|Ponce|1|P|787
    00731|PR|Ponce|Ponce|1|P|787
    00732|PR|Ponce|Ponce|1|P|787
    00733|PR|Ponce|Ponce|1|P|787
    00734|PR|Ponce|Ponce|1|P|787
    00735|PR|Ceiba|Ceiba|1|P|787
    =================================
    Bill
    You do not need a parachute to skydive. You only need a parachute to skydive twice.

  2. #2
    Join Date
    Jun 2004
    Location
    Liverpool, NY USA
    Posts
    2,509
    Found the problem. The previous developer had set up the MASTER_ZIP table as a synonym pointing to a different MASTER_ZIP table in another instance through a database link, which sqlldr doesn't allow (at least this version). When I made a work table, everything loaded fine.
    Bill
    You do not need a parachute to skydive. You only need a parachute to skydive twice.

Posting Permissions

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