Zasadniczo jest to zapytanie obrotowe. Zrobiłbym to z agregacją warunkową:
select user, access_date,
max(case when FORMFACTOR = 'Mobile' then 1 else 0 end) as KEY_MOBILE,
max(case when FORMFACTOR = 'Desktop' then 1 else 0 end) as KEY_DESKTOP,
(case when max(case when FORMFACTOR = 'Mobile' then 1 else 0 end) > 0 and
max(case when FORMFACTOR = 'Desktop' then 1 else 0 end) > 0
then 1 else 0
end) as KEY_MOBILE_DESKTOP
from table t
group by user, access_date;