Returns a list of all the hot fixes installed on a computer.

This script was tested using Perl for Microsoft Windows, available from ActiveState.

use Win32::OLE('in');
use constant wbemFlagReturnImmediately => 0x10;
use constant wbemFlagForwardOnly => 0x20;

$computer = ".";
$objWMIService = Win32::OLE->GetObject
    ("winmgmts:\\\\$computer\\root\\CIMV2") or die "WMI connection failed.\n";
$colItems = $objWMIService->ExecQuery
    ("SELECT * FROM Win32_QuickFixEngineering","WQL",wbemFlagReturnImmediately | wbemFlagForwardOnly);

foreach my $objItem (in $colItems)
      print "Caption: $objItem->{Caption}\n";
      print "CS Name: $objItem->{CSName}\n";
      print "Description: $objItem->{Description}\n";
      print "Fix Comments: $objItem->{FixComments}\n";
      print "HotFix ID: $objItem->{HotFixID}\n";
      print "Install Date: $objItem->{InstallDate}\n";
      print "Installed By: $objItem->{InstalledBy}\n";
      print "Installed On: $objItem->{InstalledOn}\n";
      print "Name: $objItem->{Name}\n";
      print "Service Pack In Effect: $objItem->{ServicePackInEffect}\n";
      print "Status: $objItem->{Status}\n";
      print "\n";