The ultimate Fabric, Power BI, SQL, and AI community-led learning event. Save €200 with code FABCOMM.
Get registeredEnhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.
I need help creating a rank column that considers the alert column and the alert date
Attached data table.
Yellow fields used in the rank criterion and green column the required result. 🙂
What I have done so far does not serve me, I attach it in case someone can correct me
-- no funciona todo queda en 1
RANKX(ALLSELECTED(CONCLUSION[ALERTA], CONCLUSION[FECHA_ALERTA], CONCLUSION[RESPONSABLE], CONCLUSION[PROBLEMA]), LASTDATE(CONCLUSION[FECHA_ALERTA]))
-- no funciona todo queda en 1
RANKX(
FILTER(CONCLUSION,
CONCLUSION[ALERTA]=EARLIER(CONCLUSION[ALERTA])
&& CONCLUSION[FECHA_ALERTA]=EARLIER(CONCLUSION[FECHA_ALERTA])
&& CONCLUSION[PROBLEMA]=EARLIER(CONCLUSION[PROBLEMA])
&& CONCLUSION[RESPONSABLE]=EARLIER(CONCLUSION[RESPONSABLE]))
, CONCLUSION[FECHA_ALERTA], ,ASC,Skip)
-- funciona ok, pero no agrupa por alerta
RANKX(
ALL(
CONCLUSION[ALERTA]
, CONCLUSION[FECHA_ALERTA]
, CONCLUSION[PROBLEMA]
, CONCLUSION[RESPONSABLE])
, CONCLUSION[FECHA_ALERTA], ,DESC,Skip)
-- funciona ok, pero no agrupa por alerta
RANKX(CONCLUSION, LASTDATE(CONCLUSION[FECHA_ALERTA]))
I managed to create a measure, but it does not help me to use it as a page filter
Adjunct measure that works 🙂
Rank_FechaAlerta = RANKX(ALLSELECTED(CONCLUSION[ALERTA], CONCLUSION[FECHA_ALERTA], CONCLUSION[RESPONSABLE], CONCLUSION[PROBLEMA]), LASTDATE(CONCLUSION[FECHA_ALERTA]))
Solved! Go to Solution.
Hi @Syndicate_Admin ,
According to your description, from the result can see, you want to rank the FECHA_ALERTA column when the ALERTA column are the same.
Here's my solution, create a calculated column.
Rank_FechaAlerta =
RANKX (
FILTER ( CONCLUSION, CONCLUSION[ALERTA] = EARLIER ( CONCLUSION[ALERTA] ) ),
CONCLUSION[FECHA_ALERTA],
,
DESC,
DENSE
)
Get the result.
I attach my sample below for your reference.
Best Regards,
Community Support Team _ kalyj
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi @Syndicate_Admin ,
According to your description, from the result can see, you want to rank the FECHA_ALERTA column when the ALERTA column are the same.
Here's my solution, create a calculated column.
Rank_FechaAlerta =
RANKX (
FILTER ( CONCLUSION, CONCLUSION[ALERTA] = EARLIER ( CONCLUSION[ALERTA] ) ),
CONCLUSION[FECHA_ALERTA],
,
DESC,
DENSE
)
Get the result.
I attach my sample below for your reference.
Best Regards,
Community Support Team _ kalyj
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
User | Count |
---|---|
77 | |
76 | |
36 | |
31 | |
29 |
User | Count |
---|---|
93 | |
79 | |
57 | |
48 | |
48 |