3 Replies Latest reply on Apr 14, 2018 12:01 PM by Nico Heinze

    IDQ Mapping

    Kamal Haria Active Member



      I am creating a mapping in IDQ 10. My requirement is as follows



      Table A



      Table B
      Source_IDColumn1Column2Column 3Column 4


      Now my requirement is as follows


      In Table A if Type1 and Type2 is 1 and 1 respectively, I need to pick the value of Column1 from Table B. Similarly if in Table A, Type1 and Type is 1 and 2 respectively, I need to pick the value of Column2 from Table B and so on. Hence my final output will be





      How to achieve this in the mapping?


      Thanks & Regards



        • 1. Re: IDQ Mapping
          Segolene Delaby Active Member



          This type of mapping can use an expression to feed the port "Value", cf picture below.


          Please us know if it helps.

          Thanks & Regards,

          • 2. Re: IDQ Mapping
            Kamal Haria Active Member

            Hi Segolene


            Thanks for your reply. This can be done, if I hard code the value, based on the Type 1 and Type 2 combination. But I need to refer to the other table (Table B) and pick the value from specific column based on Type 1 and Type 2. The reason behind this is the value in Table B can change over the period of time. So if value is picked dynamically, I dont have to worry about the change. If I hard-code it in expression without referring table B, then every time I need to change in the Expression


            I hope I am able to convey my requirement.


            Thanks & Regards



            • 3. Re: IDQ Mapping
              Nico Heinze Guru

              Perform a lookup on table B delivering attributes A, B, C, and D.

              Then use the following expression term:

              Decode( 2 * Type1 + Type2, 3, A, 4, B, 5, C, 6, D, NULL)

              If Type1 = 1 or 2 and Type2 = 1 or 2, then "2 * Type1 + Type2" will yield one of the three values 3, 4, 5, or 6. The Decode() function will deliver either port A or port B or port C or port D or NULL.