вам нужно сгруппировать в подзапрос, а затем присоединиться, чтобы найти, если макс:
declare @t table(product_id int, part_id int, appeal_id int, [year] int)
insert into @t values
(1,6,1,2016),
(1,7,1,2016),
(1,6,2,2017),
(1,7,2,2016),
(1,8,3,2016),
(1,8,1,2016);
select t.*, case when m.appeal_id is not null then 'TRUE' else '' end as Max_Check
from
@t t
left join
(
select MAX(appeal_id) appeal_id, product_id, [YEAR]
from
@t
group by product_id, [year]
) m on t.product_id = m.product_id and
t.year = m.year and
t.appeal_id = m.appeal_id