LOAD question

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Steve Rainbird

    LOAD question

    Is there way of telling the load utility that if it finds spaces in the
    input file, where it expects an integer, to insert a zero?

    Currently I am getting an error.

    SQL3116W The field value in row "F0-1" and column "46" is missing, but the
    target column is not nullable.

    TIA

    --
    Steve

  • Arun Srinivasan

    #2
    Re: LOAD question

    Using default values in the table , and complementing it with
    USEDEFAULTS keyword in the load command should get your work done..

    Comment

    • Steve Rainbird

      #3
      Re: LOAD question

      "Arun Srinivasan" <arunrocks@gmai l.comwrote in message
      news:99f01711-54ae-42cb-9ac0-707e2b9fbdd6@s8 g2000prg.google groups.com...
      Using default values in the table , and complementing it with
      USEDEFAULTS keyword in the load command should get your work done..


      Arun,

      Thanks for that but my columns all have defaults

      create table poa_ytd (
      pot_code varchar(2) default ' ' not null,
      pot_type smallint default 0 not null,
      pot_number varchar(8) default ' ' not null,
      pot_unit varchar(3) default ' ' not null,
      pot_payroll_uni t varchar(3) default ' ' not null,
      pot_badge varchar(5) default ' ' not null,
      pot_offdate integer default 0 not null,
      pot_offcode varchar(2) default ' ' not null,
      pot_oc_sections varchar(12) default ' ' not null,
      pot_accused_dob integer default 0 not null,
      pot_court_loc smallint default 0 not null,
      pot_court_timec ode smallint default 0 not null,

      and my load script says

      load from xx of asc modified by striptblanks
      usedefaults
      method L(

      So I don't think that has worked. I still get

      SQL3116W The field value in row "F0-1" and column "46" is missing, but the
      target column is not nullable.

      I think I may have to write a real program to load the data.

      Shame this isn't an oracle database. this would be trivial in sqlldr. :(

      --
      Steve

      Comment

      Working...