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

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

Reply
MeganMarkey
Regular Visitor

How to add text to blanks when using 'YEAR'

Hi! I have a column in which I'm pulling the year from another date column. What I need is for the blank columns to have the text 'In Flight' - Is anybody able to help me do this?

 

MeganMarkey_0-1764171836743.png

 

1 ACCEPTED SOLUTION
Zanqueta
Solution Supplier
Solution Supplier

Hello  @MeganMarkey

 

You want to display the year from a date column, but if the date is blank, show the text "In Flight".
This can be done with an IF condition in DAX or in Power Query.

Try it:

 

YearOrCreation =
IF(
    ISBLANK('YourTable'[DateColumn]),
    "In Flight",
    FORMAT(YEAR('YourTable'[DateColumn]), "0")
)

 

If this response was helpful in any way, I’d gladly accept a 👍much like the joy of seeing a DAX measure work first time without needing another FILTER.

Please mark it as the correct solution. It helps other community members find their way faster (and saves them from another endless loop 🌀.

 

View solution in original post

3 REPLIES 3
Kedar_Pande
Super User
Super User

@MeganMarkey 

 

Calculated Column:

Year_Display = IF(ISBLANK(YEAR([DateColumn])), "In Flight", YEAR([DateColumn]))

 

If this answer helped, please click Kudos or mark as Solution.
-Kedar
LinkedIn: https://www.linkedin.com/in/kedar-pande

Zanqueta
Solution Supplier
Solution Supplier

Hello  @MeganMarkey

 

You want to display the year from a date column, but if the date is blank, show the text "In Flight".
This can be done with an IF condition in DAX or in Power Query.

Try it:

 

YearOrCreation =
IF(
    ISBLANK('YourTable'[DateColumn]),
    "In Flight",
    FORMAT(YEAR('YourTable'[DateColumn]), "0")
)

 

If this response was helpful in any way, I’d gladly accept a 👍much like the joy of seeing a DAX measure work first time without needing another FILTER.

Please mark it as the correct solution. It helps other community members find their way faster (and saves them from another endless loop 🌀.

 

That worked perfectly! Thank you so much!

Helpful resources

Announcements
November Power BI Update Carousel

Power BI Monthly Update - November 2025

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

Fabric Data Days Carousel

Fabric Data Days

Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.