Solved

WMI Filter to exclude an application

Posted on 2009-04-14
3
673 Views
Last Modified: 2012-05-06
I want to install the PowerPoint Viewer on any machine without an instance of PowerPoint installed.  My filter code is this -

SELECT * FROM Win32_Product
WHERE Name <> 'Microsoft Office PowerPoint%'

Although it installed on a test machine with PowerPoint 2007.  Do you know what the error in my syntax is?
0
Comment
Question by:rosederekj
  • 2
3 Comments
 
LVL 70

Accepted Solution

by:
Chris Dent earned 500 total points
Comment Utility

You should be able to capture it with:

SELECT * FROM Win32_Product WHERE NOT Name LIKE 'Microsoft Office PowerPoint%'

It's just you can't use <> or = along with wildcards (% and _), only for explicit values, LIKE has to be used and if negation of that condition is needed NOT must appear before the condition.

Chris
0
 

Author Comment

by:rosederekj
Comment Utility
Thanks, much appreciated, that worked perfectly.
0
 

Author Closing Comment

by:rosederekj
Comment Utility
Perfect!
0

Featured Post

What Should I Do With This Threat Intelligence?

Are you wondering if you actually need threat intelligence? The answer is yes. We explain the basics for creating useful threat intelligence.

Join & Write a Comment

Suggested Solutions

Disabling the Directory Sync Service Account in Office 365 will stop directory synchronization from working.
Find out how to use Active Directory data for email signature management in Microsoft Exchange and Office 365.
Learn the basics of while and for loops in Python.  while loops are used for testing while, or until, a condition is met: The structure of a while loop is as follows:     while <condition>:         do something         repeate: The break statement m…
This tutorial will walk an individual through the process of transferring the five major, necessary Active Directory Roles, commonly referred to as the FSMO roles from a Windows Server 2008 domain controller to a Windows Server 2012 domain controlle…

771 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

16 Experts available now in Live!

Get 1:1 Help Now