Earn a 50% discount on the DP-600 certification exam by completing the Fabric 30 Days to Learn It challenge.
Hello guys
Can you please help me with an ideea about how can i put in DAX this?
I have table with 4 columns, Products, Date,Type and Price.
I must search all prices values with type QTR between each 2 values with type ACT and where the trend is descending to return the date of that value.Basically incrementaly must check starting from the first ACT value, that all QTR values are smaller than the next value QTR value but always between last 2 ACT values.
In below table for product A2 at 31.08.2023 the value is grater than the one from 30.09.2023 so i must return date 31.08.2023, the date where the value is grater.
Products | Date | Type | Price |
A1 | 12/31/23 | QTR | 250 |
A1 | 11/30/23 | ACT | 230 |
A1 | 10/31/23 | QTR | 200 |
A1 | 09/30/23 | QTR | 340 |
A1 | 10/31/23 | QTR | 190 |
A1 | 10/15/23 | ACT | 170 |
A1 | 09/30/23 | QTR | 160 |
A1 | 08/31/23 | QTR | 120 |
A1 | 12/07/23 | QTR | 90 |
A1 | 06/30/23 | ACT | 70 |
A1 | 05/31/23 | QTR | 60 |
A2 | 12/31/23 | QTR | 7000 |
A2 | 11/30/23 | ACT | 6500 |
A2 | 10/31/23 | QTR | 6300 |
A2 | 09/30/23 | QTR | 6200 |
A2 | 10/31/23 | QTR | 6000 |
A2 | 10/15/23 | ACT | 5600 |
A2 | 09/30/23 | QTR | 5500 |
A2 | 08/31/23 | QTR | 5700 |
A2 | 12/07/23 | QTR | 4500 |
A2 | 06/30/23 | ACT | 4000 |
A2 | 05/31/23 | QTR | 3000 |
might be easier to us a graphical solution
User | Count |
---|---|
50 | |
24 | |
18 | |
17 | |
14 |
User | Count |
---|---|
91 | |
86 | |
39 | |
25 | |
21 |