Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.
I am trying to get a list of all employees who were employed on a specific date and their total yearly salary.
So for example, I want all employees who were employed on 10-14-18 with their whole salary for 2018.
The problem I am having is when I select a specific date, the salary changes for just that date and doesn't keep the whole year salary.
Solved! Go to Solution.
hi, @kattlees
You could get it by use "ALLxxx" functions to create a measure for yearly salary like below:
Measure = VAR selectedyear = YEAR ( MAX ( 'Table'[Date] ) ) RETURN CALCULATE ( SUM ( 'Table'[Value] ), FILTER ( ALL ( 'Table'[Date] ), YEAR ( 'Table'[Date] ) = selectedyear ) )
If you need further help, please share some sample data and your expected output.
Best Regards,
Lin
hi, @kattlees
You could get it by use "ALLxxx" functions to create a measure for yearly salary like below:
Measure = VAR selectedyear = YEAR ( MAX ( 'Table'[Date] ) ) RETURN CALCULATE ( SUM ( 'Table'[Value] ), FILTER ( ALL ( 'Table'[Date] ), YEAR ( 'Table'[Date] ) = selectedyear ) )
If you need further help, please share some sample data and your expected output.
Best Regards,
Lin
I bet you need to use the ALL Function in some way.
But without an example its hard to tell what you need to do.
Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City
Check out the April 2024 Power BI update to learn about new features.
User | Count |
---|---|
105 | |
93 | |
75 | |
62 | |
50 |
User | Count |
---|---|
146 | |
109 | |
106 | |
88 | |
61 |