I need to find, in Gmail, a list of all my unread messages — which I can get via is:unread or label:unread or l:^u — which do not have the label "ZDNet."

In other words, my requirement is this:

I have 185 e-mails which are "unread" in my Inbox.
I have 174 "unread" e-mails which are labeled "ZDNet."
I need to find the 11 e-mails in my inbox that are not part of the group of 174.

How can I do this?

1 Answer 1

is:unread -label:ZDNet
  • neo: I do not have enough reputation points, but the instant I get them, I will upvote the answer. So, would the general syntax be as follows- <Has Expression> "-" <Negation Expression> or something of that sort?
    – Kanini
    Sep 7, 2010 at 11:06
  • 1
    @Kanini: You can search for <expression>. If you want to search for two expressions you can do <expr1> <expr2>. You can exclude the results of one expressions with the minus sign directly before the expression. <expr1> -<expr2> will give you all results of <expr1> excluding the results of <expr2>.
    – neo
    Sep 7, 2010 at 11:34
  • I just tried this out, and discovered that the -label operator does not work in all cases. It seems okay when applied to the inbox, but not general searches.
    – Pops
    Sep 26, 2011 at 6:51
  • @LordTorgamus: That's odd, I've never noticed that.
    – neo
    Sep 26, 2011 at 16:38
  • Does not work. nor NOT label: Apparently a bug reported in 2009. Is this something that the average dumb user would do? No. So why would the MBAs now in charge devote any resources to fixing it. Do you like the new colours? Now colours ARE important.
    – Tuntable
    Nov 13, 2016 at 1:39

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.