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

Join the Fabric FabCon Global Hackathon—running virtually through Nov 3. Open to all skill levels. $10,000 in prizes! Register now.

Reply

Calculated date is showing only earliest date instead of all dates

Hi All,

 

I have created a calculated column to get the project task end date from the start date. The next Project task start date is the end date for the current task. I even get by default the date hierarchy of that column. But now, while plotting the same in Gantt chart, the project end date is only picking the earliest one date instead of whole end date series. 

 

EndDate = 
VAR Project = FY21[Project Name]
VAR TaskStartDate = FY21[Start Date]
VAR nextTaskDate =
MINX(
FILTER(FY21, FY21[Project Name] = Project
&& FY21[Start Date] > TaskStartDate
),
FY21[Start Date]
)
Return
IF(ISBLANK(nextTaskDate), TaskStartDate, nextTaskDate)
 

Error.png

 

 

 

2 REPLIES 2
v-easonf-msft
Community Support
Community Support

Hi , @shefalinishad11 

Start date filed defines the position of task progress.Duration defines the width of task progress.

It is suggested  to use 'Start date' and 'Duration' rather than 'Start date' and 'End Date'  to create Gantt chart.

Please add another calculated column as below:

 

 

Duratation = DATEDIFF('FY 21'[Start Date],'FY 21'[End Date],DAY)

 

 

39.png

Please check my sample pbix for more details.

 

Best Regards,
Community Support Team _ Eason
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

amitchandak
Super User
Super User

@shefalinishad11 ,Can you share sample data and sample output in table format? Or a sample pbix after removing sensitive data.

Share with Power BI Enthusiasts: Full Power BI Video (20 Hours) YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube

Helpful resources

Announcements
September Power BI Update Carousel

Power BI Monthly Update - September 2025

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

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.

Top Solution Authors
Top Kudoed Authors