Earn a 50% discount on the DP-600 certification exam by completing the Fabric 30 Days to Learn It challenge.
I want to create a conditional column based on Seller column and Date column. I want to place a seller in a different unit. For example, seller named Joe was in S1 unit from January to March but then got migrated into S2 unit starting from April. But in the database, Joe is still in S1. I want to create a new column to segregate Joe into different unit.
Here is an example of the column (New Unit) that I want to create:
I'm having a trouble with dates and if else statements with DAX. Is there any other way that I can pull this off?
Solved! Go to Solution.
New Unit = IF( table[Date] < DATE(2019,4,1) && table[Seller] = "Joe", "S1" , table[Unit])
New Unit = IF( table[Date] < DATE(2019,4,1) && table[Seller] = "Joe", "S1" , table[Unit])
User | Count |
---|---|
101 | |
90 | |
79 | |
70 | |
70 |
User | Count |
---|---|
112 | |
96 | |
96 | |
75 | |
72 |