Skip to main content

You are not logged in. Your edit will be placed in a queue until it is peer reviewed.

We welcome edits that make the post easier to understand and more valuable for readers. Because community members review edits, please try to make the post substantially better than how you found it, for example, by fixing grammar or adding additional resources and hyperlinks.

2
  • 1
    What system are you running this on? I use multiple "Select *" queries and it doesn't take anywhere near 3.4 seconds, tested on thousands of computers that my software is deployed on. I do a Select * because I am getting multiple properties from the object. However, I do it a bit different: create an ObjectQuery on the Select *; get the ManagementObjectCollection; then foreach ManagementObject in the ManagementObjectCollection. Commented Aug 11, 2013 at 20:23
  • @deegee: you are right, the query itself does not take much longer with "Select *", it's just that the int parsing below is slow if iterating all the values returned instead of just NumberOfCores. Commented Sep 13, 2013 at 11:01