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

The Power BI DataViz World Championships are on! With four chances to enter, you could win a spot in the LIVE Grand Finale in Las Vegas. Show off your skills.

Reply

DAX to handle to possible options

Hi Experts

 

Is it possible to have two option in the following DAX 

See image below

Option 1Option 2
Blank CellTBC

The below works when the cell is blank i want the and or option if the cell is not blank but TBC then return TBC as opposed tp "N/A"

5.2 Blanks = 
VAR Avalue = AVERAGE([5.2])
RETURN
    IF(ISBLANK(Avalue),"N/A",Avalue)

 

 

1 REPLY 1
danextian
Super User
Super User

Hi @WhaleWatcher222 

 

You can try this:

5.2 Blanks =
VAR Avalue = AVERAGE ( [5.2] ) 
RETURN 
    COALESCE ( Avalue, [TBC measure] )

COALESCE returns the first non-blank value among the values inside it.

Note: The measure will return a text if TBC is also a text.










Did I answer your question? Mark my post as a solution!


Proud to be a Super User!









"Tell me and I’ll forget; show me and I may remember; involve me and I’ll understand."
Need Power BI consultation, get in touch with me on LinkedIn or hire me on UpWork.
Learn with me on YouTube @DAXJutsu or follow my page on Facebook @DAXJutsuPBI.

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!

FebPBI_Carousel

Power BI Monthly Update - February 2025

Check out the February 2025 Power BI update to learn about new features.

Feb2025 NL Carousel

Fabric Community Update - February 2025

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