Forum Discussion
Anonymous
7 years agoNot applicable
calculate average
hi everybody, i dont know if the title corespond to the request but i need your help. i want to calculate the averge of month promotion for each employee i use distinct it doesnt work. i want t...
- 7 years ago
Hi Anonymous ,
You can create a new calculate column like so:
1. In Query Editor, add an Index column from 1;
2. Create columns:
Column = VAR PreviousIndex = 'Table'[Index] - 1 RETURN 'Table'[id] - CALCULATE ( VALUES ( 'Table'[id] ), FILTER ( ALL ( 'Table' ), 'Table'[Index] = PreviousIndex ) ) Column 2 = IF ( 'Table'[Column] = 1, 1, BLANK () )Best Regards,
Icey Zhang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Icey
Community Support
7 years agoHi Anonymous ,
You can create a new calculate column like so:
1. In Query Editor, add an Index column from 1;
2. Create columns:
Column =
VAR PreviousIndex = 'Table'[Index] - 1
RETURN
'Table'[id]
- CALCULATE (
VALUES ( 'Table'[id] ),
FILTER ( ALL ( 'Table' ), 'Table'[Index] = PreviousIndex )
)
Column 2 =
IF ( 'Table'[Column] = 1, 1, BLANK () )
Best Regards,
Icey Zhang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Anonymous
7 years agoNot applicable
thank you Icey its was what i need i appreciate .