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

Join us for an expert-led overview of the tools and concepts you'll need to become a Certified Power BI Data Analyst and pass exam PL-300. Register now.

Reply
LMKnox
New Member

Selecting Column Data Across 2 Columns

I am trying to figure out the most efficient way to do this in Power BI and woudl welcome any suggestions.  Thank you in advance.

 

I have 2 date columns and I need to create a third date column that will, based on the content of the 2 esiting columns, either contain the date from one of the 2 date columns or todays date.

 

Date Column 1 (CONC)
~ if contains a date use this date - END
~ if blank check date column 2

 

Date Column 2 (FAD)
~ if contains a date use this date - END
~ if blank use todays date [TODAY ()] - END

 

1 ACCEPTED SOLUTION
123abc
Community Champion
Community Champion

To achieve this in Power BI, you can create a new calculated column using DAX expressions. Here's how you can create the third date column based on the conditions you provided:

 

Third Date Column =
IF(
ISBLANK([CONC]),
IF(
ISBLANK([FAD]),
TODAY(),
[FAD]
),
[CONC]
)

 

Let's break down the logic:

  • If the CONC column is blank, it checks if the FAD column is blank. If the FAD column is blank, it returns today's date using the TODAY() function. If the FAD column contains a date, it returns the date from the FAD column.

  • If the CONC column contains a date, it returns the date from the CONC column.

This calculated column will contain the dates based on the conditions you specified. You can adjust the column names as per your actual column names in your Power BI dataset.

 

If this post helps, then please consider Accepting it as the solution to help the other members find it more quickly.

 

In case there is still a problem, please feel free and explain your issue in detail, It will be my pleasure to assist you in any way I can.

View solution in original post

2 REPLIES 2
123abc
Community Champion
Community Champion

To achieve this in Power BI, you can create a new calculated column using DAX expressions. Here's how you can create the third date column based on the conditions you provided:

 

Third Date Column =
IF(
ISBLANK([CONC]),
IF(
ISBLANK([FAD]),
TODAY(),
[FAD]
),
[CONC]
)

 

Let's break down the logic:

  • If the CONC column is blank, it checks if the FAD column is blank. If the FAD column is blank, it returns today's date using the TODAY() function. If the FAD column contains a date, it returns the date from the FAD column.

  • If the CONC column contains a date, it returns the date from the CONC column.

This calculated column will contain the dates based on the conditions you specified. You can adjust the column names as per your actual column names in your Power BI dataset.

 

If this post helps, then please consider Accepting it as the solution to help the other members find it more quickly.

 

In case there is still a problem, please feel free and explain your issue in detail, It will be my pleasure to assist you in any way I can.

Thank you very much! I was so overthinking this & I now see what I was getting wrong. 

Helpful resources

Announcements
Join our Fabric User Panel

Join our Fabric User Panel

This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.

June 2025 Power BI Update Carousel

Power BI Monthly Update - June 2025

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

June 2025 community update carousel

Fabric Community Update - June 2025

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