I use PowerShell in a manner similar to what Shawn posted and probably don't even need it for that but it was convenient because someone posed a loop example that seemed a bit easier than using a DOS FOR command. What I actually use if for tis to get a disk status from all of my servers. I have an xp_CmdShell call that calls PowerShell that loops through the servers I have in a table that issues a WMI command for each server that returns the data to xp_CmdShell output that gets loaded into a table that has computed columns to parse the information and then an INSERT statement to save it all.
--Jeff Moden
Change is inevitable... Change for the better is not.