Hello,
Below is out of the box SWQL reporting for powered off virtual machines. I simply want to filter out 1 certain data center from my list. I assumed this would be fairly simple but does not appear to be. Anyone have any suggestions?
SELECT
vm.Name, vm.LastActivityDate, vm.GuestState, vm.TotalStorageSizeUsed, vm.PlatformID,
vm.Status, vm.DetailsUrl, vm.Host.HostName, vm.Host.Cluster.Name AS ClusterName
FROM
Orion.VIM.VirtualMachines vm
WHERE
SecondDiff(vm.LastActivityDate, getUtcDate()) > 2592000 AND
vm.PowerState IN('poweredOff', 'suspended', 'paused', 'saved')