Results 1 to 3 of 3
  1. #1
    Join Date
    Aug 2005
    Location
    Kuala Lumpur, MY
    Posts
    108

    Unanswered: control file / trunc(date)

    Hie, I just need a small help here..
    I have written this control file but then I want to truncate the dates but Im not sure how to do it
    Hope anyone can help..

    LOAD DATA
    INFILE '/app/ITRAKPI/TRAP/TRAP_STAGE_PPB_${YYYYMMDD}.dat'
    APPEND INTO TABLE trap_stage_ppb
    FIELDS TERMINATED BY ','
    TRAILING NULLCOLS
    (
    CREATE_DATE DATE "yyyymmddhh24miss",
    ORD_ID ,
    MS_ID ,
    DELIVERED_DATE DATE "yyyymmddhh24miss",
    UNITS ":units / 100",
    UNITS_STATE ,
    CASH_TYPE ,
    CHANNEL_TYPE ,
    RELOAD_ID ,
    DEFERRED_DATE DATE "yyyymmddhh24miss",
    VP_BATCHNR ,
    VP_CARDNR ,
    VP_ADDITIONALINFO ,
    DATE_MOD "(SELECT trunc(sysdate) FROM dual)"
    )



    this is how the data looks like
    20051028001658,1456998,60164818602,20051028001658, 3000,0,5,9,0,,R87490,,60164818602
    20051028001337,2480001,60168993370,20051028001337, 3000,0,5,9,0,,R87489,,60168993370
    20051028003630,6767759,60164131668,20051028003631, 3000,0,5,9,0,,R87493,,60164131668

    thanks in advance

  2. #2
    Join Date
    Aug 2004
    Location
    Rome, Italy
    Posts
    81
    Open the manual of Oracle Database Utilities or if you're lazy fo to the forum of Oracle.

    you are "welcome"

  3. #3
    Join Date
    Aug 2005
    Location
    Kuala Lumpur, MY
    Posts
    108
    brother.. i tried in many many ways and thats why i posted it here...
    if u say im lazy, i think posting it here and waiting for ur answer is wasting more of my time... ITS just that I cant get it and thats why im asking

    maybe u can help or at least give me the proper link...
    thanks...
    if u feel, its troublesome for you to show me by just adding 2-3 words in the control file, then its okies... maybe someone who knows will help...

    THANKKK YOUUU

Posting Permissions

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