1 Reply Latest reply on Mar 6, 2016 8:02 AM by Yuriy Fal

    Need a Tableau code for paired products

    Santanu Mukherjee

      Hi,

      I have a basket of transactions for customers

          

      customer idproduct
      12Bread
      12Pizza
      12Pretzel
      34Pizza
      34Smoothie
      45Bread
      45Pizza
      45Smoothie
      45Candy
      67Candy
      89Bread
      89Pizza
      89Pretzel
      89Smoothie
      89Candy
      89Energy Drink
      89Soda

       

      I want to know the number of customers who bought paired products like

       

         

      GroupNumber of Customers Who Bought Both
      Bread & Pizza                   3
      Bread & Pretzel                 2
      Bread & Smoothie             2
      Bread & Energy Drink        1
      Bread & Candy                  2

      ...etc.

       

       

      I want tableau to spit out this information without the user having to do anything once I select the data source and the data is available to Tableau.