select s.ResourceID ,s.Name0 ,s.operatingSystem0 ,s.User_Name0 ,Case when (select top 1 F.FilePath from v_GS_SoftwareFile F where f.FilePath like 'C:\Windows\Microsoft.NET\Framework\v3.5\' and f.ResourceID = s.ResourceID) = 'C:\Windows\Microsoft.NET\Framework\v3.5\' then 'Installed' Else 'Not Installed' End as '.Net 3.5 installed' from v_R_System s where s.operatingSystem0 not like '%server%' and (Name0 not like '%T' and Name0 not like '%B') and s.Client0 = 1 and s.Name0 in ( 'system1' ,'system2' )