SCCM SQL Query for Software not in Add Remove Programs

sccm logo 600x400

Table of Contents

Last updated on April 17th, 2023 at 12:34 am

Read Time:1 Minute, 3 Second

If you are looking for an SCCM SQL query to create a report to search for machines which do not have a particular software installed, you can use the following:

Select Distinct
 sys.Netbios_Name0,
 sys.User_Domain0,
 sys.User_Name0
FROM
 v_R_System sys
JOIN v_Add_Remove_Programs arp
 ON sys.ResourceID = arp.ResourceID
WHERE
 sys.ResourceID not in
 (select sys.ResourceID
 from
 v_R_System sys
 JOIN v_Add_Remove_Programs arp ON sys.ResourceID = arp.ResourceID
 WHERE
 DisplayName0 = @displayname)

Then you can use the variable @displayname to choose from a drop down of software that is in the SCCM database pulled from client machines. The query you can use for that is:

select
 DisplayName0
 from
 v_Add_Remove_Programs

You should be able to use these to create a report that will prompt for a selection from all the available data.

More Queries

Our full range of SQL and WQL Collection queries are available here.

Feedback

If you have any questions or feedback about this post, or if you would like us to create any queries for you, please go ahead and leave us a message below in the comments section and we will get back to you as quick as we can.

Click to rate this post!
[Total: 1 Average: 5]

Discover more from TechyGeeksHome

Subscribe to get the latest posts to your email.

Leave us a message...

This site uses Akismet to reduce spam. Learn how your comment data is processed.