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
andi2333
Helper I
Helper I

Comparison between weeks

Hi again,

continuing my learning journey for PowerBI, another - most likely - simple question:

 

I have a chart which shows the progress of open IT incidents over time  - calculated with the following query:

 

openTicketsOverTime =
VAR _cDate = MAX(MyCalendar[Date])
RETURN
CALCULATE(
    DISTINCTCOUNT('Aspen Tickets'[Number]),
    FILTER(
        'Aspen Tickets',
        'Aspen Tickets'[Created(opened_at)]  <= _cDate
        && ('Aspen Tickets'[Closed]) > _cDate || ISBLANK('Aspen Tickets'[Closed])
    )
)
 
This results in a chart like this:
andi2333_0-1697794363031.png

 

I know would like to put another visual in my dashboard which compares the number of open tickets from this week to the week before and spits out the drop or increase in percentage...I am not sure what the best way to do this would be, and I would appreciate any suggestions.

 

Thanks

3 REPLIES 3
BA_Pete
Super User
Super User

Hi @andi2333 ,

 

I recognise that measure! 😉

I think this depends on which type of week you're using - are you using just regular calendar week (WEEKNUM) or are you using a custom fiscal week from a 4-4-5 calendar?

 

Pete



Now accepting Kudos! If my post helped you, why not give it a thumbs-up?

Proud to be a Datanaut!




Hi! Correct, and I really appreciate your support again!!

I am using a regular weeknum() function in my calendar. 
thanks!!

 

No worries 🙂

You should be able to do something like this:

_openTickets_WoW_% =
VAR _currDate = MAX(MyCalendar[Date])
VAR _currOpen =
CALCULATE(
    DISTINCTCOUNT('Aspen Tickets'[Number]),
    FILTER(
        'Aspen Tickets',
        'Aspen Tickets'[Created(opened_at)]  <= _currDate
        && ('Aspen Tickets'[Closed]) > _currDate || ISBLANK('Aspen Tickets'[Closed])
    )
)
VAR _prevDate = _currDate - 7
VAR _prevOpen =
CALCULATE(
    DISTINCTCOUNT('Aspen Tickets'[Number]),
    FILTER(
        'Aspen Tickets',
        'Aspen Tickets'[Created(opened_at)]  <= _prevDate
        && ('Aspen Tickets'[Closed]) > _prevDate || ISBLANK('Aspen Tickets'[Closed])
    )
)
VAR _diff = _currOpen - _prevOpen
RETURN
DIVIDE(_diff, _prevOpen, 0)

 

Pete



Now accepting Kudos! If my post helped you, why not give it a thumbs-up?

Proud to be a Datanaut!




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.