select PMD.DeviceGuid as DeviceGuid
  FROM 
       PowerManagedDevices                AS PMD
 INNER 
  JOIN PowerPlanConfigurationDeviceLinks  as PPCDL
                                                  ON PMD.DeviceGuid = PPCDL.DeviceGuid
WHERE PMD.OSVersion LIKE '10.%'
  AND PMD.IsPowerManaged = 0