Forum Discussion

reemadsouza's avatar
reemadsouza
Frequent Visitor
1 year ago
Solved

Help with measure

I am trying to calculate the volume/Sales at plant level. Example below , so the total volume sold for AM Sports Depot reppeats in each line for sales plant column

 the example above uses this formula listed below:-

Sales Plant =
CALCULATE(
    SUM(STG_INVENTORY_PROGRESSION[Volume Sold]),
    ALLEXCEPT(
        STG_INVENTORY_PROGRESSION,
        STG_INVENTORY_PROGRESSION[COMPANY_NAME],
        STG_INVENTORY_PROGRESSION[REGION_NAME],
        STG_INVENTORY_PROGRESSION[PLANT],STG_INVENTORY_PROGRESSION[YEAR_MONTH]
    )
)

 

 

I am Trying to create a measure which would give similar results. the new formula I am trying to recreate is given below:-

 

here geography name in the above formula  = Plant in the below

 

Sales Plant =
CALCULATE(
[Ticket Volume Delivered Qty],
ALLEXCEPT('1 - Company', '1 - Company'[Company Name]),
ALLEXCEPT('3 - Geography', '3 - Geography'[Geography Region Name], '3 - Geography'[Geography Name]),
ALLEXCEPT('Date', 'Date'[Year/Month Name Short])
)

 

but the results I am getting with the second formula are as below.

 

I want the value 722897.68 for Sales plant for AM sports depot to repeat down like how it is in the above image.

  • Anonymous's avatar
    Anonymous
    1 year ago

    Hi reemadsouza 

     

    Thanks for the additions, I can now fully understand what you are trying to do.
    But since your second measure uses a DAX formula that involves multiple tables, and we don't know what your structure of those tables and the relationships between them are, it's hard for us to find the cause of the problem and then advise you.

    Try constructing a new Matrix visual using the fields in the second DAX formula('1 - Company'[Company Name], '3 - Geography'[Geography Name]), then put that measure into the Values of the Matrix visual and see if that works.

    If not works, please provide some dummy data that maintains the same data structure and tell us the relationship between the tables.

     

    Best Regards,
    Jarvis Tang
    If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

4 Replies