Forum Discussion

u92690's avatar
u92690
Frequent Visitor
5 years ago

Measure with multiple slicers applying (Beginner level) - example posted

Hey Friends,

 

I have a quiet simple issue, I guess, but im not getting to sort it out. I have two tabels, one with the cases and the other one with the tests, all of them broken down by administrative territory levels (Level 2 have several Level 3, but also several L2 can have just one Level 3) and data. I have created the measure cases/test, and i would like to get it calculated for the exact combinations of territory levels I select. However, I dont know how to do it for all the levels at the same time. Please, find below the example in which you'll see it so clearly.

 

PIBX -> https://drive.google.com/file/d/1ky3lIS8gjImwT5O4GJh3bheYkSMnMy5C/view?usp=sharing 

Tables -> https://drive.google.com/file/d/1bKvRqhEv664ptYtmq3f6wPCfgpiCcqmG/view?usp=sharing

 

Thanks!

 

Ashish_Mathur 

3 Replies

  • Hi,

    In the Cases table, you should select Date and Cases and "Unpivot all other columns" - this will leave you with 3 columns.  Do the same for the Tests table as well.  The territories table should also just have one column.  Build relationships from the Attribute column of Cases and Tests table to the Territories table. 

  • Anonymous's avatar
    Anonymous
    Not applicable

    Hi u92690 ,

     

    Sorry for that the information you have provided is not making the problem clear to me.

    Could you please tell me the expected output via some screenshots?

    By the way, I have created a new table in case you want to split the level type:

    Table = 
        var _1=DISTINCT( SELECTCOLUMNS('Territories',"Type",LEFT([Region - Level 1],2),"Level",RIGHT([Region - Level 1],1)))
        var _2=DISTINCT( SELECTCOLUMNS('Territories',"Type",LEFT([Region - Level 2],2),"Level",RIGHT([Region - Level 2],1)))
        var _3=DISTINCT( SELECTCOLUMNS('Territories',"Type",LEFT([Region - Level 3],2),"Level",RIGHT([Region - Level 3],1)))
    return DISTINCT(UNION(_1,_2,_3))
    

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

  • Anonymous's avatar
    Anonymous
    Not applicable

    Hi u92690 ,

     

    Could you tell me if your problem has been solved? If it is, kindly Accept it as the solution. More people will benefit from it.

    Best Regards,
    Eyelyn Qin