Error Group BY

HI,

I have below query and is giving me error for: Each GROUP BY expression must contain at least one column that is not an outer reference. cant figure out?

Thanks.

(
select A.EMPLID
from TESTSCORE
WHERE A.LEARN_ID IN ('ST102','ST103','ST104')

...
and A.EMPLID not IN
(
select EMPLID
from TESTSCORE
WHERE LEARN_ID IN ('ST102','ST103','ST104')
group by EMPLID
Having count(EMPLID) < 3)

1 Like

Thanks Scott! it was the Alias.. Ahhhh.. :slight_smile: