The ultimate Fabric, Power BI, SQL, and AI community-led learning event. Save €200 with code FABCOMM.
Get registeredCompete to become Power BI Data Viz World Champion! First round ends August 18th. Get started.
Hi all,
I am new to Power BI and want to write a calculation using following columns
Quantity on hand , Po on order and YTD average sales and Shipping Date which are direct column from table.
The calculation should work like
If shipping date in data set is not null, then calculation should be:
Else the calculation should be:
Also if Quantity on hand, Po on order and YTD average sales is null then Cal=0
I am unable to get null function in this calculation.
Any suggestions what am i missing.
Solved! Go to Solution.
@Anonymous ,
check if this code helps or not,
Cal =
SWITCH (
TRUE (),
'Table'[Shipping Date] <> BLANK (), 'Table'[Quantity on hand] + 'Table'[YTD average sales],
'Table'[Quantity on hand] = BLANK ()
|| 'Table'[Po on order] = BLANK ()
|| 'Table'[YTD average sales] = BLANK (), 0,
'Table'[Quantity on hand] + 'Table'[YTD average sales]
)
Thanks,
Arul
@Anonymous ,
check if this code helps or not,
Cal =
SWITCH (
TRUE (),
'Table'[Shipping Date] <> BLANK (), 'Table'[Quantity on hand] + 'Table'[YTD average sales],
'Table'[Quantity on hand] = BLANK ()
|| 'Table'[Po on order] = BLANK ()
|| 'Table'[YTD average sales] = BLANK (), 0,
'Table'[Quantity on hand] + 'Table'[YTD average sales]
)
Thanks,
Arul
User | Count |
---|---|
80 | |
78 | |
37 | |
34 | |
31 |
User | Count |
---|---|
93 | |
81 | |
60 | |
49 | |
49 |