Power BI is turning 10! Tune in for a special live episode on July 24 with behind-the-scenes stories, product evolution highlights, and a sneak peek at what’s in store for the future.
Save the dateEnhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.
Hi
I have 2 columns start date and end date where i have end dates lesser than start dates. If my end date is before start date I want to replace end date with start date value, thereby the difference between start and end dates = 0. I found creating measure using DateDiff in power bi for this purpose but I want to clean this in power query. How to do it.?
I was unable to give column values in Replace option under end_date column. It is accepting only distinct values present in the data.
Solved! Go to Solution.
@sam89 Create a new column (Add Column)
= if [end date] < [start date] then [start date] else [end date]
Then remove your end date column and rename the new column to end date.
@sam89 Create a new column (Add Column)
= if [end date] < [start date] then [start date] else [end date]
Then remove your end date column and rename the new column to end date.
Check out the July 2025 Power BI update to learn about new features.
This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.
User | Count |
---|---|
9 | |
7 | |
5 | |
5 | |
4 |
User | Count |
---|---|
10 | |
8 | |
7 | |
6 | |
6 |