Forum Discussion
IF between 2 tables
Hi there,
I'm struggling with an IF statement. I have 3 tables: Actve, Ratings2016, Ratings2017. The two ratings tables have a relationship to the Active table using the employee ID with no duplicates.
What I want to do is say that someone is a Higher Performer if their ratings over the last 2 years were greater than 2.5 (because our scale is 1 to 3), otherwise they are not a high performer.
I tried doing this as a column on the Active table but no luck and I get an aggregate error saying it needs a COUNT, MIN, SUM or something:
Column = IF(('Ratings2016'[Overall Performance Rating] >= "2.5" && 'Ratings2017[Overall Performance Rating] >= "2.5"), "HiPo","Not a HiPo")
What am I doing wrong? Any help would be great please. Thank you.
- Anonymous8 years ago
Wow. I think I figured this out on my own after all of these hours. It seems to work! Woohoo!! I'm so proud of myself :) :) :) :)
Column = IF (
Calculate ( Count ('Ratings2016'[Overall Performance Rating]),'Ratings2016'[Overall Performance Rating] >= 2.5) &&
Calculate ( Count ('Ratings2017'[Overall Performance Rating]),'Ratings2017'[Overall Performance Rating] >= 2.5), "HiPo",
"Not a HiPo"
)
3 Replies
- jthomsonSolution Sage
Not sure why the 2.5 is in ""s?
- AnonymousNot applicable
Usually it needs to be. I tried without, but still no luck.
- AnonymousNot applicable
Wow. I think I figured this out on my own after all of these hours. It seems to work! Woohoo!! I'm so proud of myself :) :) :) :)
Column = IF (
Calculate ( Count ('Ratings2016'[Overall Performance Rating]),'Ratings2016'[Overall Performance Rating] >= 2.5) &&
Calculate ( Count ('Ratings2017'[Overall Performance Rating]),'Ratings2017'[Overall Performance Rating] >= 2.5), "HiPo",
"Not a HiPo"
)