Hitachi Vantara Pentaho Community Forums
Results 1 to 2 of 2

Thread: help.how to make increment update in kettle?(insert/update,timestamp)

  1. #1
    Join Date
    Mar 2009
    Posts
    1

    Default help.how to make increment update in kettle?(insert/update,timestamp)

    hi all,

    here is my situation:
    the TABLE_USER in the source database has a N_STATUS field,when N_STATUS changed, i should save the history of user status change
    in the FACT_USER table .
    for example

    Code:
     
    1.  
    source: 
        TABLE_USER.N_STATUS=1
    face : 
        (one record for the status)
        FACT_USER.N_STATUS=1,
        FACT_USER.STATUS_CHANGE_STARTTIME=today
        FACT_USER.STATUS_CHANGE_STARTTIME=2099-01-01(means newest)
    2.status change
    source: 
        TABLE_USER.N_STATUS=2
    face: 
        (tow record for the history of status)
        FACT_USER.N_STATUS=1,
        FACT_USER.STATUS_CHANGE_STARTTIME=today
        FACT_USER.STATUS_CHANGE_ENDTIME=justnow
     
        FACT_USER.N_STATUS=2,
        FACT_USER.STATUS_CHANGE_STARTTIME=justnow
        FACT_USER.STATUS_CHANGE_ENDTIME=2099-01-01
    for now ,I use the insert/update transforms,but i can't update the
    STARTTIME and ENDTIME.

    any reply will be userful,thx!

  2. #2

    Default

    when i understand you right, you should use the Dimension Lookup/Update step.
    you set the keys, the fields and at the bottom you set the date fields,
    everything else works on its own :P

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Privacy Policy | Legal Notices | Safe Harbor Privacy Policy

Copyright © 2005 - 2019 Hitachi Vantara Corporation. All Rights Reserved.