Q: How can I use PowerShell to query WMI Query Language?
A: If you want to use PowerShell to run a WMI Query Language (WQL) statement, you can use the following approach in which you replace $query with your own WQL statement:
$query = 'select TotalPhysicalMemory from Win32_ComputerSystem' get-wmiobject -query $query -Namespace "root\CIMV2"
0 comments
Hide comments