Forum Discussion

drwillia's avatar
drwillia
Helper I
4 years ago
Solved

Split Row Value by Allocation Table %

Hi, This problem is a little beyond me,  I would like to break each record out based on the Commodity dimension. If that Dimension matches the allocation table then create additonal rows for each ...
  • tamerj1's avatar
    4 years ago

    drwillia 
    Here is the sample file with the solution https://we.tl/t-Cp8LuiRxh9

    Rebates (Summary) = 
    SELECTCOLUMNS (
        GENERATE (
            Rebates,
            ADDCOLUMNS (
                Allocation,
                "Allocated Revenue", Rebates[Revenue] * Allocation[Allocation],
                "Allocated Component", Allocation[Component] 
            )
        ),
        "Date", [Date],
        "Branch Code", [Branch Code],
        "Company Lookup", [Company Lookup],
        "Revenue", [Allocated Revenue],
        "IBP Component", [IBP Component],
        "Source", [Source],
        "Commodity", [Allocated Component]
    )
  • tamerj1's avatar
    tamerj1
    4 years ago

    Hi drwillia 
    Yes you are absolutely right. Here is the updated file with minor change https://we.tl/t-JjBH8gDGjW

    Rebates (Summary) = 
    SELECTCOLUMNS (
        GENERATE (
            Rebates,
            ADDCOLUMNS (
                RELATEDTABLE ( Allocation ),
                "Allocated Revenue", Rebates[Revenue] * Allocation[Allocation],
                "Allocated Component", Allocation[Component] 
            )
        ),
        "Date", [Date],
        "Branch Code", [Branch Code],
        "Company Lookup", [Company Lookup],
        "Revenue", [Allocated Revenue],
        "IBP Component", [IBP Component],
        "Source", [Source],
        "Commodity", [Allocated Component]
    )