From 84595900f67273ac7d1d03aec53f9d43d809d6de Mon Sep 17 00:00:00 2001 From: Moshe Weitzman Date: Wed, 30 Oct 2024 08:47:23 -0400 Subject: [PATCH] Add negation operator example to filter docs (#6150) --- docs/output-formats-filters.md | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/docs/output-formats-filters.md b/docs/output-formats-filters.md index d370536cce..4eaedb4d8e 100644 --- a/docs/output-formats-filters.md +++ b/docs/output-formats-filters.md @@ -108,6 +108,13 @@ Other fields in the output may be searched by using a simple expression in the ` ```shell $ drush pm:list --filter='status=enabled' ``` + +Exclude rows via the negation operator `!`: + +```shell +drush watchdog:show --filter="type!=locale" +``` + To search for fields that contain a string using the operator `*=`, or match a regular expression with the `~=` operator. For example, to find all views whose machine name contains the word *content*: ```shell drush views:list --filter='machine-name*=content'