Re: Collection problem

Tech-Archive recommends: Fix windows errors by optimizing your registry



Arrhh.... of course that is the reason :-) I should have known this :-)

Thanks Lars!

Br.

Kristian F. Thomsen

"Lars Norman Søndergaard" <lns@xxxxxxxxxxxxx> wrote in message
news:uLSXXpyaFHA.2520@xxxxxxxxxxxxxxxxxxxxxxx
> Hi Kristian,
>
> The reason why you see this behaviour is really rooted in SQL: for each
> SMS_R_System.ResourceID multiple entries exists in Add/Remove Programs.
> Consequently you get "false" hits.
>
> Reformulate the query using a subselect statement:
> 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 where
> sms_R_SYSTEM.ResourceID not in (select
> SMS_G_System_ADD_REMOVE_PROGRAMS.ResourceID where
> SMS_G_System_ADD_REMOVE_PROGRAMS.DisplayName != "Microsoft .NET Framework
> 1.1")
>
> Thanks
> Lars Norman Søndergaard
>
> "Kristian F. Thomsen" <kft@xxxxxxxxxxxx> skrev i en meddelelse
> news:O5nBbppaFHA.1384@xxxxxxxxxxxxxxxxxxxxxxx
>> Hi all,
>>
>> I have created a collection using this 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_ADD_REMOVE_PROGRAMS on
>> SMS_G_System_ADD_REMOVE_PROGRAMS.ResourceID = SMS_R_System.ResourceId
>> where SMS_G_System_ADD_REMOVE_PROGRAMS.DisplayName != "Microsoft .NET
>> Framework 1.1"
>>
>> As you can see, I only want to se the computers that does not have the
>> .NET Framework 1.1 installed. But computers which has .NET Framework
>> installed, also appears in my collection.... why ?
>>
>> Thanks in advance
>>
>> Br.
>>
>> Kristian F. Thomsen
>>
>
>


.