Rank Function not behaving as desired

BI 4.1, SP5 Update 3

I have a table as per the screenshot

rank, endtime, cycleoid (a measure), primary machine

I wish to have a rank function that will reset on PRIMARY MACHINE. For this, I have created the below variable. However as per the screenshot, the ranking is not behaving correctly, I get a β€˜1’ for every rank entry.

=Rank([CycleOID1];[TruckCycles].[Primary Machine])

Any help would be appreciated.
Capture.PNG


fghs_1987 :uk: (BOB member since 2008-01-02)

Primary machine is the same for all those rows?


Mak 1 :uk: (BOB member since 2005-01-06)

Hi Mak, no it isnt, it eventually changes (but many rows later)


fghs_1987 :uk: (BOB member since 2008-01-02)

Can you define what sits under this?

[CycleOID1]

Are you sure that the calculation context is set right?


Mak 1 :uk: (BOB member since 2005-01-06)

It is a Measure variable with datatype numeric. I have also tried recreating it with a dimension object but the same problem occurs.


fghs_1987 :uk: (BOB member since 2008-01-02)

I have resolved it. I don’t know if this is new behaviour with BI 4.1 SP5 but basically you must specify whether you wish for Top or Bottom. The resolved variable is this:

=Rank([Endtime];Top;[TruckCycles].[Primary Machine])


fghs_1987 :uk: (BOB member since 2008-01-02)

Nice one Joseph, will have to check mine.
Thought Top was the default, in any case, but may be wrong :).

From the help :cuss: .
Keyword No (Top is default)


Mak 1 :uk: (BOB member since 2005-01-06)