Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more
Hi All,
I am stuck on 3 and or if condition and it does not work properly. can you please check below table. I need to check if customer Ali and Buyer is not A or B or C is 1 and others 2. below formula does not work for it.
Result = if(Sales[Customer]="Ali"
&& Sales[Buyer]<>"A"
|| Sales[Customer]="Ali"
&& Sales[Buyer]<>"B"
|| Sales[Customer]="Ali"
&& Sales[Buyer]<>"C",1,2)
| Customer | Buyer | Result |
| Ali | A | 2 |
| Veli | A | 1 |
| Murat | B | 1 |
| Evren | C | 1 |
| Ali | A | 2 |
| Ali | C | 2 |
| Ali | D | 1 |
@selpaqm ,
Check these
Result = if(Sales[Customer]="Ali"
&& not(Sales[Buyer] in("A","B","C")),1,2)
OR
Result = if(Sales[Customer]="Ali"
&& Sales[Buyer] in("A","B","C"),2,1)
The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!
| User | Count |
|---|---|
| 39 | |
| 37 | |
| 33 | |
| 32 | |
| 29 |
| User | Count |
|---|---|
| 133 | |
| 88 | |
| 85 | |
| 68 | |
| 64 |