Forum Discussion
masplin
8 years agoImpactful Individual
Filtering calculation using values in Pivot table
Our budget has been defined as monthly numbers and exisits in a table where the budget number is on a row where the date is 1/mm/yyyy. This date is then related to my main date table so can be plotte...
- Anonymous8 years ago
HI masplin,
It will be help for analysis if you share some sample data.
In addition, you can also try to use below formula if it works for your scenario:Budget GP Current Month = VAR current_date = MIN ( DateTable[Day] ) RETURN CALCULATE ( [Budget GP], FILTER ( Detail_Budget_16, YEAR ( Detail_Budget_16[Month] ) = YEAR ( current_date ) && MONTH ( Detail_Budget_16[Month] ) = MONTH ( current_date ) ) )Regards
XIaoxin Sheng
Anonymous
8 years agoNot applicable
HI masplin,
It will be help for analysis if you share some sample data.
In addition, you can also try to use below formula if it works for your scenario:
Budget GP Current Month =
VAR current_date =
MIN ( DateTable[Day] )
RETURN
CALCULATE (
[Budget GP],
FILTER (
Detail_Budget_16,
YEAR ( Detail_Budget_16[Month] ) = YEAR ( current_date )
&& MONTH ( Detail_Budget_16[Month] ) = MONTH ( current_date )
)
)
Regards
XIaoxin Sheng
masplin
8 years agoImpactful Individual
So if i have apivot table with severla dates on say the columns witll the Min function slelect that date for each column as the current_date?
If so then yes this is what i'm looking for thanks
- Anonymous8 years agoNot applicable
Hi masplin,
For single row contents, min function will return current date.
If it works on summary row content, it will return the min date from the summary records.Regards,
Xiaoxin sheng