Link to home
Start Free TrialLog in
Avatar of smart Z
smart Z

asked on

Collection help

Hi there,

I would like to have a collection for All Windows XP 32bit computer with AutoCAD2009 but also does not have AutoCAD2010.

I would also like to have another collection with All Windows XP 64bit with AutoCAD2009 and AutoCAD 2010.

Thanks,
Avatar of Exemplar
Exemplar
Flag of United States of America image

Hello smartmanwin!

I think I can help you out with this one.  Please follow the directions below and you should be able to get an accurate account of the AutoCAD installs in your organization.

Part I.  Create "with" Collections
To begin with, you need to create the collection that identifies which systems have AutoCAD2009 installed for both WinXP/32 and WinXP/64.  This can be done in a relatively easy fashion.  Create two new collections and name them like:  "WinXP-32bit with AutoCAD2009" and "WinXP-64bit with AutoCAD2009"

There are a few WQL queries for this sort of thing, but I usually prefer this query over the Add/Remove Programs query:
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_SoftwareFile on SMS_G_System_SoftwareFile.ResourceID = SMS_R_System.ResourceID where SMS_G_System_SoftwareFile.FileName = "AAAAA" and SMS_G_System_SoftwareFile.FileVersion >= "BB" and SMS_G_System_SoftwareFile.FilePath like "%\\Program Files\\CCCCC\\CCCCC\\%"

Key:
AAAAA = the .exe file for AutoCAD2009
BB = .exe file version (you get this in the .exe properties)
CCCCC = specific folders within C:\Programs Files where the .exe resides

You will want to point the "WinXP-32bit with AutoCAD2009" collection at a previously created collection that identifies All WinXP 32bit systems.  You will want to point the "WinXP-64bit with AutoCAD2009" collection at the collection that identifies All WinXP 64bit systems.  This can be done by using Collection Limiting.

At this time, you have created two collections that identify all WinXP systems that DO have AutoCAD2009 installed.

Part II. Write down Collection IDs
Next, please right-click --> properties of the two collections and write down the Collection IDs.  Keep the IDs ready, you will need them shortly.

Part III.  Create "not in" Collections
Now we need to move on to the 'without AutoCAD' collections.  Again, you need to create two new collections, name them:  "WinXP-32bit without AutoCAD2009" and "WinXP-64bit without AutoCAD2009"

The WQL query for this is commonly referred to as the "not in" query.  Use this query on the two 'without' collections:
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 where ResourceId not in (select ResourceID from SMS_CM_RES_COLL_EEEEEEEE)

Key:
EEEEEEEE = Collect ID of first two collections

Again you will want to utilize the Collection Limiting function and point at the same collections as the first two collections, in this case, the All WinXP 32bit Systems and the All WinXP 64bit Systems.

When this is complete, you have two new collections that identify which servers DO NOT have AutoCAD2009 installed.

Part IV.  End Results
If you set this up correctly, as ConfigMgr runs its discoveries, these collections will update accordingly and you will have an accurate look at your organization's workstation to AutoCAD installs.

/cheers
Avatar of jparekh
jparekh

You can get the OS from System Resource (or Operating Systems table).  I don't have AutoCad installed but you can query the Add Remove Programs for the install.  See the example below.. I'm looking for Windows XP machines and program that starts with Demo.
=

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_ADD_REMOVE_PROGRAMS on SMS_G_System_ADD_REMOVE_PROGRAMS.ResourceId = SMS_R_System.ResourceId where SMS_R_System.OperatingSystemNameandVersion like "%Workstation 5.1%" and SMS_G_System_ADD_REMOVE_PROGRAMS.DisplayName like "Demo%"

Open in new window

x32 machines only

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 where SMS_G_System_COMPUTER_SYSTEM.SystemType = "X86-based PC"

Look for x64 only

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 where SMS_G_System_COMPUTER_SYSTEM.SystemType = "X64-based PC"
Avatar of smart Z

ASKER

I do not want to list the PCs that have both version of AutoCAD 2009/10. I just want to list the PCs that have AutoCAD2009 but do not have AutoCAD 2010. How can I do that with one query. Thats all I am asking.
The query below will also list the PCs that have AutoCAD 2009 and AutoCAD 2010. I want to exclude the PCs that already have AutoCAD 2010.  
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_ADD_REMOVE_PROGRAMS on SMS_G_System_ADD_REMOVE_PROGRAMS.ResourceID = SMS_R_System.ResourceId where SMS_G_System_COMPUTER_SYSTEM.SystemType = "X64-based PC" and SMS_G_System_ADD_REMOVE_PROGRAMS.DisplayName like "AutoCAD 2009"
 Regards
Avatar of smart Z

ASKER

I will just exclude the computers by Computer names they are just few of them. That will be my last resort.
Thanks,
Using the query that I identified above (again below), you can easily differentiate between the two AutoCAD installs based upon the file version.

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_SoftwareFile on SMS_G_System_SoftwareFile.ResourceID = SMS_R_System.ResourceID where SMS_G_System_SoftwareFile.FileName = "AAAAA" and SMS_G_System_SoftwareFile.FileVersion >= "BB" and SMS_G_System_SoftwareFile.FilePath like "%\\Program Files\\CCCCC\\CCCCC\\%"

Thanks,
Ex
ASKER CERTIFIED SOLUTION
Avatar of TarekIsmail
TarekIsmail
Flag of Qatar image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of smart Z

ASKER

to the point.