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

Power BI is turning 10! Let’s celebrate together with dataviz contests, interactive sessions, and giveaways. Register now.

Reply
unnijoy
Post Partisan
Post Partisan

DAX formula help

I have 3 column in my data. Two of them are date column. Learning Date Completed and Course date Completed.

Now i need to create a line graph in which x axix sould be month from January-2019 and it should go on.  And one line should show the count of month for Learning Date Completed and the other for Course date Completed. Below is the data set. 

COUNTRYRegionLearning DATE_COMPLETEDCourse DATE_COMPLETED
CanadaNorth America  
CanadaNorth America March-2019
CanadaNorth AmericaFebruary-2019January-2019
CanadaNorth America February-2019
BulgariaEuropeMarch-2019March-2019
BulgariaEurope March-2019
PhilippinesPhilippinesMarch-2019March-2019
PhilippinesPhilippinesMarch-2019March-2019
PhilippinesPhilippinesMarch-2019March-2019
BulgariaEurope March-2019
BulgariaEurope February-2019
BulgariaEurope  
BulgariaEurope February-2019
BulgariaEurope  
BulgariaEurope February-2019
BulgariaEurope  
BulgariaEurope  
BulgariaEurope  
BulgariaEurope  
BulgariaEurope April-2019
BulgariaEurope  
UKEurope  
UKEurope January-2019
UKEurope  
UKEurope February-2019
BulgariaEurope  
CanadaNorth America  
CanadaNorth America  
UKEurope  
BulgariaEurope  
BulgariaEurope  
BulgariaEurope  
BulgariaEurope  
PhilippinesPhilippinesMarch-2019March-2019
PhilippinesPhilippinesMarch-2019March-2019
CanadaNorth AmericaFebruary-2019January-2019
CanadaNorth America March-2019
UKEurope  
BulgariaEurope  
BulgariaEurope  
BulgariaEurope  
BulgariaEurope  
BulgariaEurope  
PhilippinesPhilippinesMarch-2019March-2019
UKEurope  
UKEurope  
BulgariaEurope  
BulgariaEuropeMarch-2019March-2019
BulgariaEurope  

 I have 2 filter on top which are Country and Region.  Please help

 

2 REPLIES 2
gooranga1
Power Participant
Power Participant

If you have 2 dates yo will need to unpivot them to join them to 1 date dimension.

 

If you go to edit queries and select the 2 date columsn and select unpivot. You can then join the 1 value column to date dimension and use the attribute column as the legend.

 

Data1.PNGData2.PNGData3.PNG

jthomson
Solution Sage
Solution Sage

You need to create a date table that you use for your x-axis, then make two relationships to your data table for each date field

Helpful resources

Announcements
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.