Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
5 years ago
Solved

SUM IF / Date Issue

Hi there,

 

I am having trouble with one of my measures. Esentially I am trying to sum the sales from 2 tables... Both have SKU and Quarter in the rows. When I am looking at Sales, I believe the measure is summing sales from every quarter in the e-comm table and not taking into account the quarter.

 

I currently have a many:many relationship linked to both tables along with the below measure. Any help is greatly appreciated.

 

Thanks!

  • Anonymous's avatar
    Anonymous
    5 years ago

    Anonymous 

    Try create the following measure:

     

    Measure = Sumx(All('LicenseBrand Data'),[Sales $]) + Sumx(All('E-Comm'),[Merch & TY])

     


    Paul Zheng _ Community Support Team
    If this post helps, please Accept it as the solution to help the other members find it more quickly.

2 Replies

  • Please explain your reasoning for applying that type of relationship.

     

    Would you consider both tables to be Fact tables?  Are there Dimension elements in these tables?  Would it be better to apply some gentle normalization to arrive at a Star schema data model?

  • Anonymous's avatar
    Anonymous
    Not applicable

    Anonymous 

    Try create the following measure:

     

    Measure = Sumx(All('LicenseBrand Data'),[Sales $]) + Sumx(All('E-Comm'),[Merch & TY])

     


    Paul Zheng _ Community Support Team
    If this post helps, please Accept it as the solution to help the other members find it more quickly.