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

Earn a 50% discount on the DP-600 certification exam by completing the Fabric 30 Days to Learn It challenge.

Reply
Anonymous
Not applicable

Formatting a calculation from Tableau to Power BI

I am moving a report from Tableau into Power BI.  I am having some trouble recreating the fomulas, as the syntax is different.  How would I write this Tableau calcuation in Power BI:

 

IF [Include Admin Schedule Hrs] AND NOT(ISNULL([AdminSchedHours]))

THEN

IIF(ISNULL([Worked Hours]), MIN([AdminSchedHours], IIF(ISNULL([MedianExpectedTaskHours]), 8,NULL ) ) , [Worked Hours])

3 REPLIES 3
amitchandak
Super User
Super User

@Anonymous , A measure like this

IF ( [Include Admin Schedule Hrs]>0 && NOT(isblank([AdminSchedHours])), IF(isblank([Worked Hours]), MIN([AdminSchedHours]), IF(ISNULL([MedianExpectedTaskHours]), 8,NULL ) )
, [Worked Hours])

Anonymous
Not applicable

Thank you for your help.  I am getting an error, it doesn't like ISNULL

 

Included Admin Schedule Hrs (Adj) = IF(NOT(ISBLANK('CRNA Time Management'[AdminSchedHours])), IF(ISBLANK('CRNA Time Management'[WorkedHours], MIN('CRNA Time Management'[AdminSchedHours]),IF(ISNULL('CRNA Time Management'[MedianExpectedTaskHours]),8,NULL)), 'CRNA Time Management'[WorkedHours]))

 

 

DaisySara_0-1602000715348.png

 

Anonymous
Not applicable

I revised to this, think it's OK

 

Included Admin Schedule Hrs (Adj) = IF(NOT(ISBLANK('CRNA Time Management'[AdminSchedHours])), IF(ISBLANK('CRNA Time Management'[WorkedHours]), MIN('CRNA Time Management'[AdminSchedHours]),IF(ISBLANK('CRNA Time Management'[MedianExpectedTaskHours]), 8, 0)), 0)

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.