Thursday, December 08, 2005

WMI: Changes to Workstation Inventory

Joe pointed out that in the workstation inventory script that I recently posted, it’s considerably more efficient to use objectCategory=’computer’ than objectClass. I made the recommended change, and sure enough, it worked, and worked more quickly. Thanks joe!

If you want to follow along, consider the following change…


"Select Name, Location from " & strLdapPath & " Where objectClass='computer'"

to

"Select Name, Location from " & strLdapPath & " Where objectCategory='computer'"


After I’ve completed some more work on the script, I’ll post the new version in it’s entirety, incorporating this update.

No comments: