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

We've captured the moments from FabCon & SQLCon that everyone is talking about, and we are bringing them to the community, live and on-demand. Starts on April 14th. Register now

Reply
Anonymous
Not applicable

Merging two graphs with date as x axis

Hi all, 

 

I'm trying to merge two graphs onto one to highlight some trends over the past year. 

 

The data i'm using is safety certificates so each one has an expiry date and an issue date. I'm trying to show on the graph, how many expired in each month of the year and how many were issued. (As seen in picture on 2 separate graphs). 

joshuap_0-1613132290100.png

However, when I go to merge these two on a graph, it will either use the expiry date or issue date as the x axis and then both will show the same valules (as seen below). 

joshuap_1-1613132380677.png

Does anyone know how I can use dates as a x-axis that aren't linked to either date? Or is there a simpler way for me to do this?

 

Thanks in advance.

1 ACCEPTED SOLUTION
Anonymous
Not applicable

Hi @Anonymous ,

You can create a Date table first and set date field of Date table as X axis for your column chart. Then create two measures as below:

 

Count of rk_issuedate =
CALCULATE (
    SUM ( table[rk] ),
    FILTER (
        ALLSELECTED ( table ),
        table[issue date] <= SELECTEDVALUE ( Date[date] )
    )
)​
Count of rk_expirydate =
CALCULATE (
    SUM ( table[rk] ),
    FILTER (
        ALLSELECTED ( table ),
        table[expiry date] <= SELECTEDVALUE ( Date[date] )
    )
)

 

Best Regards

View solution in original post

2 REPLIES 2
Anonymous
Not applicable

Hi @Anonymous ,

You can create a Date table first and set date field of Date table as X axis for your column chart. Then create two measures as below:

 

Count of rk_issuedate =
CALCULATE (
    SUM ( table[rk] ),
    FILTER (
        ALLSELECTED ( table ),
        table[issue date] <= SELECTEDVALUE ( Date[date] )
    )
)​
Count of rk_expirydate =
CALCULATE (
    SUM ( table[rk] ),
    FILTER (
        ALLSELECTED ( table ),
        table[expiry date] <= SELECTEDVALUE ( Date[date] )
    )
)

 

Best Regards

amitchandak
Super User
Super User

@Anonymous ,You have to create a common date table. If they are from the same table there will one inactive join which you can activate using userealtionship

 

refer examplehttps://community.powerbi.com/t5/Community-Blog/HR-Analytics-Active-Employee-Hire-and-Termination-trend/ba-p/882970

 

To get the best of the time intelligence function. Make sure you have a date calendar and it has been marked as the date in model view. Also, join it with the date column of your fact/s. Refer :radacad sqlbi My Video Series Appreciate your Kudos.

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
New to Fabric survey Carousel

New to Fabric Survey

If you have recently started exploring Fabric, we'd love to hear how it's going. Your feedback can help with product improvements.

Power BI DataViz World Championships carousel

Power BI DataViz World Championships - June 2026

A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.

Join our Fabric User Panel

Join our Fabric User Panel

Share feedback directly with Fabric product managers, participate in targeted research studies and influence the Fabric roadmap.

March Power BI Update Carousel

Power BI Community Update - March 2026

Check out the March 2026 Power BI update to learn about new features.