Answered by:
SCCM Collection Query vs. SCCM Query

Question
-
Hello All,
I have a question related to how the Queries work in SCCM.
When I create a collection based on a query, limited to an existing collection I get a number of results, with the default collection parameters shown.
When I create a query (in the query tab), limited to the same existing collection and get only the Names of the resources, I get significantly more results (Ex: the collection has 20 000 items, the collection query gives me 18 000 items and the query alone gives me 19 500 items).
Can you please tell me why is this happening, shouldn't the number of resources be the same, if I am running the same query?
I was thinking that this might be heppening because of the parrameters that I pull out from the query.
Thank you,
Spineano- Edited by Ovidiu Spinean Thursday, August 27, 2009 2:09 PM
Thursday, August 27, 2009 2:05 PM
Answers
-
Try with Resourceid insted of Name with the same logic I feel its an issue with duplicate resourceids for a single machine. which is for obsolete machine.
- Proposed as answer by Eric C. Mattoon Monday, September 14, 2009 3:08 PM
- Marked as answer by Eric C. Mattoon Tuesday, September 15, 2009 8:54 PM
Saturday, September 5, 2009 5:33 PM
All replies
-
Maybe you didn't select "Omit duplicate rows (Select distinct)" in the query.
Kent Agerlund | http://scug.dk/members/Agerlund/default.aspx | The Danish community for System Center productsThursday, August 27, 2009 2:22 PM -
I was thinking about that, and it's sellectedThursday, August 27, 2009 2:23 PM
-
How aggressively do you have the Site Maintenance Task -> Delete Aged Discovery Data setting? Default is to only do this 1x/wk and only set to Delete data older than (days) = 90.
In the past I've seen inconsistencies such as those you describe when using the default values if you don't carefully craft the WQL statements to filter out "stale" but as yet undeleted records.
EricThursday, August 27, 2009 5:20 PM -
I am creating the collection for Reporting purposes (to see exactly after a deployment how many computers have installed it) and I am manually deleting the duplicate entryes (via other collections that find the duplicates entries, and Delete Special).
The Delete Aged Discovery Data is set to run daily, and it deletes the ones that are older than 60 days.
But still, the difference is too bing, 1 500 items diference for the same query.Friday, August 28, 2009 6:47 AM -
Is this a Software Distribution Advertisement or a Software Updates Deployment? If it is the latter, I'm going to move your post to the SUM forum as there are folks over there that can typically provide more comprehensive answers as to their reporting.Saturday, August 29, 2009 2:57 PM
-
This is for a Software Distribution Advertisement, but it is a general question.
Why does the same query pulls out different number or items in collections and in query tab?Thursday, September 3, 2009 1:00 PM -
Try with Resourceid insted of Name with the same logic I feel its an issue with duplicate resourceids for a single machine. which is for obsolete machine.
- Proposed as answer by Eric C. Mattoon Monday, September 14, 2009 3:08 PM
- Marked as answer by Eric C. Mattoon Tuesday, September 15, 2009 8:54 PM
Saturday, September 5, 2009 5:33 PM