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,
I have a formula which I am able to apply as a new column in the PowerBi Desktop table itself but when I am trying to do the same in the Power Query Editor as a custom column, then I can't get it to work.
Can someone tell me what my error is?
Is there a logic error which I am considering?
Working formula within PowerBI "New column":
Attempted new formula within PowerBi Power Query Editor "Custom column": (NOT WORKING)
if([purchasePrice]=null,0,
if([purchasePrice]<2,(([purchasePriceTotal]+[#"Pick&Pack_Total"])*0.2))
if([purchasePrice]>=2 && [purchasePrice]<10,(([purchasePriceTotal]+[#"Pick&Pack_Total"])*0.2))
if([purchasePrice]>=10 && [purchasePrice]<50,(([purchasePriceTotal]+[#"Pick&Pack_Total"])*0.15))
if([purchasePrice]>=50,(([purchasePriceTotal]+[#"Pick&Pack_Total"])*0.1)))
Try changing all instances of [#"Pick&Pack_Total"] with [Pick&Pack_Total]
Hi @johnt75
I have tried the change but without change/success. The Error seems to be in the first row.
That's the DAX syntax, the power query syntax is
if condition then result1 else result2
The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!
| User | Count |
|---|---|
| 41 | |
| 39 | |
| 37 | |
| 29 | |
| 24 |
| User | Count |
|---|---|
| 118 | |
| 98 | |
| 70 | |
| 69 | |
| 65 |