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

Enhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.

Reply
Dash7
Frequent Visitor

Multiple Line chart - two date columns

Hello,

 I have table with tasks, that contains columns: TASK, Created Date of task, Start Date and Completition Date.
 I need to create the line chart with number of tasks Completed vs total number of tasks created in period of time(x:month, Y1: TASK, Y2:SumCompletedTasks(DAX)). In other words How many tasks were created vs how many was completed, month by month.


 I can not use on X axis (month) columns  Created Date of task or Completition Date because it will show me only data one of them, not separate. 

 The problem is when I create separate DATE table I need to link it to the main table. When I link it to Start date or completition date it does not have a sense.

Example Data:

TaskCreatedStart DateCompletion date
Task 1   07/30/2023   07/31/2023    08/15/2023
Task 2   07/30/2023  

Task 3

   08/05/2023     08/05/2023    08/30/2023

Task 4

   08/05/2023   

Based on the above data: Completed (0) vs Created (2) in July.
Could anyone help me to solve that issue? 

2 REPLIES 2
Anonymous
Not applicable

Hi  @Dash7 ,

 

Here are the steps you can follow:

1. In power query – select [Created], [Start Date] ,[Completion date] – Transform – Unpivot Column.

vyangliumsft_1-1704784569245.png

2. Create measure.

create =
COUNTX(
    FILTER(ALL('Table'),   YEAR('Table'[Value])=YEAR(MAX('Table'[Value]))&&MONTH('Table'[Value])=MONTH(MAX('Table'[Value]))&&'Table'[Attribute]="Created"),[Task])
complete =
COUNTX(
    FILTER(ALL('Table'),    YEAR('Table'[Value])=YEAR(MAX('Table'[Value]))&&MONTH('Table'[Value])=MONTH(MAX('Table'[Value]))&&'Table'[Attribute]="Completion date"),[Task])

3. Result:

vyangliumsft_2-1704784595852.png

 

 

Best Regards,

Liu Yang

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

Thank you, but is there any other chance to do that without duplicating the rows? My data source is sharepoint list, and i am not sure if it will not impact the charts i already built 

Helpful resources

Announcements
July 2025 community update carousel

Fabric Community Update - July 2025

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

July PBI25 Carousel

Power BI Monthly Update - July 2025

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

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.