6 Replies Latest reply on Jun 17, 2012 10:42 AM by Joe Mako

    Data Blending Question

    Edwin Fung

      I'm trying to create a simple report with 2 tables from 2 data soruces (one from excel, one from datawarehouse). Both tables share a common field material ID.


      Table 1:


      material ID


      Table 2:

      material ID

      Sales Revenue

      Sales Date


      I'm trying to create a report showing the Total Sales Revenue by Product (without showing the material ID, because I want to look at the trend). I tried but once I took out the material ID, the sales # will be gone. 


      Is there a solution to this data blending challenges?

        • 1. Re: Data Blending Question
          Tracy Rodgers

          Hi Edwin,


          The linking field needs to be somewhere on the view if the two data sources are to be blended. Depending on the view, perhaps material ID could be added to the level of detail?




          • 2. Re: Data Blending Question
            Edwin Fung

            I saw some other users menetioned the same thing. But it's not working. I tried but it gave me some wierd report with the numbers overlapping each other. 

            • 3. Re: Data Blending Question

              Hi Edwin,


              If it is OK, would it be possible for you to post the sample workbook as a packaged extract?




              • 4. Re: Data Blending Question

                Hi Edwin,


                When you add a field to the Level of Detail, as I understand, Tableau will give you the children of each aggregation on the view by the field that is on the Level of Detail. If your visualization does not have the setup to break these down into individual rows (have the Level of Detail field on the rows/columns), Tableau will produce overlapping marks. This might be a desired view if you wanted to set features like 'Transparency' on and wanted to show a graph of the data.


                In your particular situation, I think the issue could be because Tableau is doing a LEFT OUTER JOIN with your data from the primary source to the secondary source and is producing multiple records for each Product. I have tried to replicate the data in the attached workbook. Can you have a look and confirm if this is what you are experiencing?




                • 5. Re: Data Blending Question
                  Robert Morton

                  Hi Edwin,


                  Tableau does not yet support data blending based on linking fields which are not part of the visualization. This is a common request and would enable some interesting analysis. We are interested in improving the capabilities of data blending, but I cannot comment on a specific timeframe for this.


                  In the meantime you may be able to get some of the functionality you desire by creating an ad-hoc group from the relationship between your fine-grained field "material ID" and your coarse-grained "Product" field. Below I'll describe the steps you should take, which follow the instructions in this KB article: Creating Primary Groups from a Secondary Source Using Data Blending


                  1) Create a new worksheet.

                  2) From "Table 2" drag "material ID" to the Rows shelf.

                  3) From "Table 1" drag "Product" to the Rows shelf.

                  4) Right-click on "Product" and choose "Create Primary Group...".  This will bring up the ad-hoc group dialog, which allows you to manually tune the grouping and give this new field a meaningful name (such as "Product").

                  5) Click OK and observe that your primary data source for "Table 2" has been updated to include this new ad-hoc group, representing data captured from the secondary.

                  6) You can now create a visualization of Sales Revenue by Product. At this point you may no longer need the "Table 1" data source, since its simple content is now entirely captured within the "Table 2" data source.


                  I hope this helps,


                  • 6. Re: Data Blending Question
                    Joe Mako

                    Another option is to use a table calculation, as in the attached. The big benefit of this is that when the underlying data changes, the computation continues to work, where as the ad-hoc group would need to be recreated if the data changes.