Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Don't miss out! 2025 Microsoft Fabric Community Conference, March 31 - April 2, Las Vegas, Nevada. Use code MSCUST for a $150 discount. Prices go up February 11th. Register now.

Reply
Shantanuj
Frequent Visitor

Equivalent of tableau Function: Lookup and ZN

Dear all,

I am using the following tableau formula:

 

zn(LOOKUP(SUM([Backlog]),0))

 

I need to convert this formula in power bi.

Thanks in advance for help

1 ACCEPTED SOLUTION
ribisht17
Community Champion
Community Champion

@Shantanuj 

 

 

https://www.sqlbi.com/articles/how-to-return-0-instead-of-blank-in-dax/  (if below wont work)

Sol=
IF (
    CALCULATE ( SUM ( Backlog) ) = BLANK (),
    0,
    CALCULATE ( SUM ( Backlog) )
)

Regards,
Ritesh

 

Since I have experience with Tableau, I suppose neither technique will necessarily work. In essence, there is a difference between BLANK and Nothing, therefore utilising the LOOKUP function is necessary because there is nothing there.

 

I see this option for that one,

 

https://devoworx.net/how-to-show-zero-values-in-power-bi-chart/

 

Watch my Linkedin Post Post | Feed | LinkedIn

BEFORE

ribisht17_0-1684077631862.png

 

STEP 1

You need to create a separate table for Ship Mode

ribisht17_2-1684045178043.png

STEP 2

 

ribisht17_1-1684045143516.png

 

STEP 3

New Sales Relationship = CALCULATE(sum(Orders[Sales])+0)

ribisht17_0-1684045111147.png

 

 

Mark my post as a solution if it helped you| Munde and Kudis (Ladies and Gentlemen) I like your Kudos!! !!
My YT Channel Dancing With Data !! Connect on Linkedin !!Power BI for Tableau Users 

View solution in original post

6 REPLIES 6
ribisht17
Community Champion
Community Champion

Please mark the answer and help the community in return, if it did not help please let us know

 

Regards,

Ritesh

Hi Ribisht,

 

 I am facing an issue after applying below mentioned formula in powerbi. In PowerBI if we set the value as current week and for tableau if we set value as previous week, then required numbers are matching. But when setting both Tableau and PowerBi to point to the current week, numbers are not matching. Can you please suggest what could be the possible issue?

 

Thanks and Regards

Shantanuj

Hi Ribisht,

 Currently, implementing other aspects as well. Once completed if it works, will mark this as a solution. And if it doesn't work will let you know.

 

Thanks and Regards

Shantanuj  

Not a problem, you can watch my video on the same topic as well

 

PL 300 Series Use Case -Null to Zero (DAX) - YouTube

 

Regards,

Ritesh

ribisht17
Community Champion
Community Champion

@Shantanuj 

 

 

https://www.sqlbi.com/articles/how-to-return-0-instead-of-blank-in-dax/  (if below wont work)

Sol=
IF (
    CALCULATE ( SUM ( Backlog) ) = BLANK (),
    0,
    CALCULATE ( SUM ( Backlog) )
)

Regards,
Ritesh

 

Since I have experience with Tableau, I suppose neither technique will necessarily work. In essence, there is a difference between BLANK and Nothing, therefore utilising the LOOKUP function is necessary because there is nothing there.

 

I see this option for that one,

 

https://devoworx.net/how-to-show-zero-values-in-power-bi-chart/

 

Watch my Linkedin Post Post | Feed | LinkedIn

BEFORE

ribisht17_0-1684077631862.png

 

STEP 1

You need to create a separate table for Ship Mode

ribisht17_2-1684045178043.png

STEP 2

 

ribisht17_1-1684045143516.png

 

STEP 3

New Sales Relationship = CALCULATE(sum(Orders[Sales])+0)

ribisht17_0-1684045111147.png

 

 

Mark my post as a solution if it helped you| Munde and Kudis (Ladies and Gentlemen) I like your Kudos!! !!
My YT Channel Dancing With Data !! Connect on Linkedin !!Power BI for Tableau Users 
Ritaf1983
Super User
Super User

Hi @Shantanuj 

Could you please attach a sample PBIX file/table that can be copied (no screenshot) and your desired results?

Regards,
Rita Fainshtein | Microsoft MVP
https://www.linkedin.com/in/rita-fainshtein/
Blog : https://www.madeiradata.com/profile/ritaf/profile

Helpful resources

Announcements
Las Vegas 2025

Join us at the Microsoft Fabric Community Conference

March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount!

December 2024

A Year in Review - December 2024

Find out what content was popular in the Fabric community during 2024.