cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Bian Regular Visitor
Regular Visitor

Re: How do you select the value of yesterday

my formula would look like below:

SumRunStatus = CALCULATE(SUM('LogTable'[RunStatus]),'LogTable'[Date]=Date(YEAR(now()),Month(now()),(DAY(now())-1)))
Not sure why it's empty for you.
Is runstatus number?

Re: How do you select the value of yesterday

Does your date table cover the time period you are reporting on?

Re: How do you select the value of yesterday

Yes I am just trying to grab yesterday.  My date table starts in 2014 and goes to end of 2019

Re: How do you select the value of yesterday

No, forget RunStatus.  That should be ActiveCount.  I just included runstatus because I didn't want to reorder all the columns to show in a single jpeg.  That is just a "Placeholder".  Yes active count is a whole number.  

Bian Regular Visitor
Regular Visitor

Re: How do you select the value of yesterday

Could you post your Measure?

Re: How do you select the value of yesterday

OMG that worked!!  Dude you saved my life haha.  Was about to punch my monitor.  I was using my calendar table the whole time, which may have been the issue??  

 

Here is the actual formula with proper column names.  Why would my date table not work?  Typically instead of 

'ClubDayStats'[LogDate] I would use 'Calendar'[Date]

Re: How do you select the value of yesterday

It looks like your date column increments in 7 day jumps.  I can see that causing problems.

 

dates_column.jpg

Re: How do you select the value of yesterday

I noticed that as well, but it is because I organize by MonthNum.  If I don't do that the numbers are messed up on a line graph.  I don't think that is the issue?  The order of the column itself should not matter if all the dates are there and they are organized accordingly?  That is just how the data is stored?

Re: How do you select the value of yesterday

You know what... maybe that is causing an issue.  How do I fix that?  It is a sorting issue I presume, but not sure how to fix.  Again, I had to organize a lot of cells by monthnum otherwise they would be out of order

Re: How do you select the value of yesterday

It depends on how your date table is built but what is happening in the measure it is filtering the date table for every date that = say 1/2/2019 and it is not finding a line for 1/2/2019 in your date column so it is returning a blank.

 

Your date column should have every date for the whole spacn so 365 rows a year.  For sorting months, you can always set the sort coumn of month name to be month number so it appears Jan, Feb, Mar in charts.