Home » Microsoft » Query to Determine 32 or 64 bit Operating System

sql-server
In many cases there are a need create a collection with either all Windows 7 – x86 or all Windows 7 x64 installed.This can be used for targeting only a specific platform with an update or a program.

I do this by querying the SCCM inventory, SMS_G_System_COMPUTER_SYSTEM.SystemType which returns “x64-based PC”or “X86-based PC”.

Query to find all Windows 7 – x64

select SMS_R_SYSTEM.ResourceID,SMS_R_SYSTEM.ResourceType,SMS_R_SYSTEM.Name, SMS_R_SYSTEM.SMSUniqueIdentifier,SMS_R_SYSTEM.ResourceDomainORWorkgroup, SMS_R_SYSTEM.Client from SMS_R_System inner join SMS_G_System_COMPUTER_SYSTEM on SMS_G_System_COMPUTER_SYSTEM.ResourceID = SMS_R_System.ResourceId inner join SMS_G_System_OPERATING_SYSTEM on SMS_G_System_OPERATING_SYSTEM.ResourceID = SMS_R_System.ResourceId where SMS_G_System_COMPUTER_SYSTEM.SystemType = “x64-based PC” and SMS_G_System_OPERATING_SYSTEM.Caption like “Microsoft Windows 7%”

And the query for Windows 7 -x86

select SMS_R_SYSTEM.ResourceID,SMS_R_SYSTEM.ResourceType,SMS_R_SYSTEM.Name, SMS_R_SYSTEM.SMSUniqueIdentifier, SMS_R_SYSTEM.ResourceDomainORWorkgroup,SMS_R_SYSTEM.Client from SMS_R_System inner join SMS_G_System_COMPUTER_SYSTEM on SMS_G_System_COMPUTER_SYSTEM.ResourceID = SMS_R_System.ResourceId inner join SMS_G_System_OPERATING_SYSTEM on SMS_G_System_OPERATING_SYSTEM.ResourceID = SMS_R_System.ResourceId where SMS_G_System_COMPUTER_SYSTEM.SystemType = “X86-based PC” and SMS_G_System_OPERATING_SYSTEM.Caption like “Microsoft Windows 7%”

Comments

comments

Latest

skype Using Skype To Replace Landline Phone
riff Bеѕt VR Apps and Games for Meditation
google pixel The World Is On Your Palm Now, Go Mobile
security lock Top In-Demand Skills For Cloud Computing
Facebook Messenger Lite Facebook Messenger Lite Announced

Tech Geek Today

Tech Geek Today

MonTueWedThuFriSatSun
      1
9101112131415
16171819202122
23242526272829
3031     
    123
45678910
11121314151617
252627282930 
       
 123456
78910111213
14151617181920
21222324252627
28293031   
       

Subscribe To The Technology Geek

Archives