Forum Discussion
DynamicsHS
4 years agoHelper II
Can you use a USERELATIONSHIP for two dates?
Hi, I want to show a table with active employees based on the year. Someone provided me with a userelationship measure to get the terminated employees to show. e.g. Terminated within = CALCUL...
tamerj1
4 years agoCommunity Champion
Hi DynamicsHS
In this case you need to do the oppsite. You need to remove the filter from the date table and then iterate ove the table to manually count the number of employees that are active in the selected 'Date'[Date] in the filter context. Something like:
=
CALCULATE (
SUMX (
Payroll,
IF (
Payroll[Start Date] <= MAX ( 'Date'[Date] )
&& Payroll[End Date] >= MAX ( 'Date'[Date] ),
1
)
),
REMOVEFILTERS ( 'Date' )
)
DynamicsHS
4 years agoHelper II
- tamerj14 years agoCommunity Champion
Instead of REMOVEFILTERS you may try CROSSFILTER to NONE