Hitachi Vantara Pentaho Community Forums
Results 1 to 3 of 3

Thread: Combining the data from two tables based on conditions

  1. #1
    Join Date
    Oct 2017
    Posts
    2

    Default Combining the data from two tables based on conditions

    Hi,

    I am new to PDI world but had more than a decade of experience in Data Stage, Informatica, ODI and other ETL tools. I am trying to combine the data from two input data sets, apply some conditions on the columns and then insert or update the data into the target table:

    Input Source 1:
    EmployeeID
    Middle Name_1
    Suffix_1

    Input Source 2:
    EmployeeID
    Middle Name_2
    Suffix_2

    Now, I have to check if the Middle Name_1 is NULL then Middle Name_2 will be sent to the target table but I am not sure how I can achieve this in PDI. Any help is greatly appreciated!
    Thanks
    NIvas

  2. #2
    Join Date
    Apr 2008
    Posts
    4,696

    Default

    How I would approach this:

    Input1 (Sorted on EmployeeID) |
    ------------------------------------Merge Join (on EmployeeID) -> Calculator (NVL MiddleName1, MiddleName2) -> Insert/Update (To Destination Table)
    Input2 (Sorted on EmployeeID) |

  3. #3
    Join Date
    Oct 2017
    Posts
    2

    Default

    Quote Originally Posted by gutlez View Post
    How I would approach this:

    Input1 (Sorted on EmployeeID) |
    ------------------------------------Merge Join (on EmployeeID) -> Calculator (NVL MiddleName1, MiddleName2) -> Insert/Update (To Destination Table)
    Input2 (Sorted on EmployeeID) |
    Thank you.It worked!

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.