Forum Discussion

BCWdesign's avatar
BCWdesign
Frequent Visitor
1 year ago
Solved

Help with ranking

 

I have two tables 

Once shows the numebr fo requests by Local Authrity in England the other is the population 

I have a measure which divides the populaiton by the number of requests (%population)

I want to rank these in order to see which Authorities have the highest percentage 

 

Measure 3 = RANKX('Initial Request',[0-25 Population2],[% Population],DESC,Dense)
This measure produces a rank of 1 or 2 -- I have been unable to find a way to rank these 
where am I going wrong?
  • BCWdesign The RANKX function should be applied to a table that contains the data you want to rank, and it should reference the correct columns

     

    DAX
    Measure 3 = RANKX(
    ALL('Initial Request'),
    [% Population],
    ,
    DESC,
    DENSE
    )

     

    Additionally, make sure that % Population is a measure that calculates the percentage of the population for each authority. If % Population is not already defined, you can create it :

    % Population = DIVIDE([0-25 Population2], [Total Population])

2 Replies

  • BCWdesign The RANKX function should be applied to a table that contains the data you want to rank, and it should reference the correct columns

     

    DAX
    Measure 3 = RANKX(
    ALL('Initial Request'),
    [% Population],
    ,
    DESC,
    DENSE
    )

     

    Additionally, make sure that % Population is a measure that calculates the percentage of the population for each authority. If % Population is not already defined, you can create it :

    % Population = DIVIDE([0-25 Population2], [Total Population])