2 Replies Latest reply on Nov 20, 2018 5:43 AM by Loic Bamdé

    Data blending with Invoice and Contract

    Loic Bamdé

      Hi Community,


      First post for me, sorry if I didn't search enough.


      I would like to have a list of my Projects and my Contracts with or without Invoice, but with some measures and a part of details...that's the problem for me when I blend the data.


      I have two sources : one is CONTRACT, the other is INVOICE

      An INVOICE is linked to 1 CONTRACT only.

      A CONTRACT can have (or not) several INVOICES.

      A CONTRACT is linked to a projet

      A INVOICE is linked to a project as well

      All links are full outer join.


      If i use the source CONTRACT, i can have the "project name", the "contract number" and the "countd( contract number)" without issue

      If i use the source INVOICE, i can have the "project name", the "invoice number" and the "invoice amount" without issue

      Now, i use the source CONTRACT a main source, with source INVOICE as secondary source, i can have the "project name", the "contract number", the  "countd( contract number)", the invoice amount" without issue

      But, if i add the "invoice number", i have the star *

      That's the native working of Tableau.

      It's recommended to use INVOICE source as the main source. But, the fact is that not all the contract has invoice. Consequently, the countd(contract number) will change and reflects only the number of contract that have invoices, right ?

      If i intent to take the countd(contract number) that is in the CONTRACT source (as secondary source), i have an error.

      I intented to put {FIXED [Id Contract] : countd(contract number)} but it's not allowed.


      How can I "pre-calculate" (like a over partition by or something like that) the count(contract number) of the CONTRACT source (as secondary source) and put in the report that has the project number, the invoice number, the invoice amount ?

      Actually, is it possible ? does it make sense ?



      Note : the two sources are linked through the field ID_CONTRACT