10 Replies Latest reply: Jan 25, 2018 4:09 PM by Marco Wedel RSS

    Apply Map/ Left Join to get only one value

    Fayez Khan

      Hi,

       

      I have a scenario where in my main table is like:

       

      Account_No      BSG         Volume

      A123                   1                100

      A123                   2                50

      A123                   3                80

      A867                   1                1000

       

      Now I have another table which is like :

       

      Account_No              Sales

      A123                           850

      A867                           900

       

      I have to get the sale values in the main table. The problem I am facing is that if I use a Left Join with Sales table my Sales number will get inflated or duplicated since there are more than one same Account No in the main table. Appply map will go the same.

       

      The desired output is:

       

      Account_No      BSG         Volume      Sales

      A123                   1                100            850

      A123                   2                50

      A123                   3                80

      A867                   1                1000          950