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

Re: How to display sales YTD and sales last YTD over years?

Result is correct but it should come without selection, Anyway thanks for your time Ashish...



Super User
Super User

Re: How to display sales YTD and sales last YTD over years?

Hi,

How should the "Month till" be determined?  Should it be till the month of Today?


Regards,
Ashish Mathur
http://www.ashishmathur.com
https://www.linkedin.com/in/excelenthusiasts/
khanashique Frequent Visitor
Frequent Visitor

Re: How to display sales YTD and sales last YTD over years?

Yes...i think now it is clear for you

Super User
Super User

Re: How to display sales YTD and sales last YTD over years?

Hi,

Try these measures:

Measure = CALCULATE([Total Bal],DATESBETWEEN(DimTable[Date],DATE(YEAR(TODAY()),1,1),today()))
Measure 2 = CALCULATE([Total Bal],DATESBETWEEN(DimTable[Date],DATE(YEAR(TODAY())-1,1,1),EDATE(today(),-12)))

Hope this helps.

Untitled.png


Regards,
Ashish Mathur
http://www.ashishmathur.com
https://www.linkedin.com/in/excelenthusiasts/
khanashique Frequent Visitor
Frequent Visitor

Re: How to display sales YTD and sales last YTD over years?

WOW, Finally this works... Thanks Ashish...

Measure 2 = CALCULATE([Total Bal],DATESBETWEEN(DimTable[Date],DATE(YEAR(TODAY())-1,1,1),EDATE(today(),-12)))

Once again thanks a lot for your effort and time... ^_^

Super User
Super User

Re: How to display sales YTD and sales last YTD over years?

You are welcome.  If my reply helped, please mark it as Answer.


Regards,
Ashish Mathur
http://www.ashishmathur.com
https://www.linkedin.com/in/excelenthusiasts/
JMcAvaney Visitor
Visitor

Re: How to display sales YTD and sales last YTD over years?

@Ashish_Mathur 

 

This solution is perfect for what I'm currently working on! I just need one slight tweak. On your second measure you have listed there, is it possible to bring in Prior YTD Sales, minus one day? ie We report 6/12/19 data on 6/13/19, and when comparing YTD to YTD, the measure given has results that compare YTD 6/13/18 to YTD 6/12/19. I just need to move the parameters for the LYTD measure back one day. I've experimented in the syntax of the measure and can't get that date moved back.

Super User
Super User

Re: How to display sales YTD and sales last YTD over years?

Hi,

Try this measure

Measure 2 = CALCULATE([Total Bal],DATESBETWEEN(DimTable[Date],DATE(YEAR(TODAY())-1,1,1),EDATE(today(),-12)-1))

Hope this helps.


Regards,
Ashish Mathur
http://www.ashishmathur.com
https://www.linkedin.com/in/excelenthusiasts/

Helpful resources

Announcements
Can You Solve These Challenge

Challenge: Can You Solve These?

Find out how to participate in the first Power BI 'Can You Solve These?' challenge.

New Badges

Incoming: New and Improved Badges

Exciting news: We've given our badges an overhaul and added brand news ones.

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.

Analytics in Azure virtual event

Analytics in Azure virtual event

Experience a limitless analytics service built to ingest, prep, manage, and serve data for immediate use in Power BI.

Users Online
Currently online: 274 members 2,020 guests
Please welcome our newest community members: