cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
armand453 Frequent Visitor
Frequent Visitor

DAX - Compare Actual month vs January

Hello,

 

I have a table with revenue by month on several year and i'd like to compare the growth of the revenu of the current month vs january of the same year. Is it possible to do that please?

 

 

1 ACCEPTED SOLUTION

Accepted Solutions
Super User
Super User

Re: DAX - Compare Actual month vs January

@armand453

 

Try this MEASURE

Please see attached file as well

 

Growth Measure =
VAR mymonth =
    SELECTEDVALUE ( 'Calendar'[Date].[MonthNo] ) - 1
VAR Jan_Same_year =
    CALCULATE (
        SUM ( Table1[Sales] ),
        DATEADD ( 'Calendar'[Date], - mymonth, MONTH )
    )
RETURN
    DIVIDE ( SUM ( Table1[Sales] ), Jan_Same_year ) - 1

againstJan.png

Try my new Power BI game Cross the River

View solution in original post

2 REPLIES 2
Super User
Super User

Re: DAX - Compare Actual month vs January

@armand453

 

Try this MEASURE

Please see attached file as well

 

Growth Measure =
VAR mymonth =
    SELECTEDVALUE ( 'Calendar'[Date].[MonthNo] ) - 1
VAR Jan_Same_year =
    CALCULATE (
        SUM ( Table1[Sales] ),
        DATEADD ( 'Calendar'[Date], - mymonth, MONTH )
    )
RETURN
    DIVIDE ( SUM ( Table1[Sales] ), Jan_Same_year ) - 1

againstJan.png

Try my new Power BI game Cross the River

View solution in original post

armand453 Frequent Visitor
Frequent Visitor

Re: DAX - Compare Actual month vs January

Thank you your solution work

Helpful resources

Announcements
Ask Amir Anything

Exclusive LIVE Community Event No. 2 – Ask Amir Anything

Next in our Triple A series: Ask Amir Netz questions about the latest updates, features and future.

Ask Amanda Anything Q&A

Ask Amanda Anything Q&A

Learn the answers to some of the questions asked during the Amanda Triple A event.

October 2019 Community Highlights

October 2019 Community Highlights

October was a busy month in the community. Read the recap article to learn about some of the events and content.

New Solution Badges

New Solution Badges

Two waves of brand new solution badges are coming! Read the article for more information on our new community badges.

Users Online
Currently online: 385 members 3,775 guests
Please welcome our newest community members: