7 Matching Annotations
  1. Nov 2022
    1. You can do searches that exclude certain labels. That is, searches like this will do what you expect: (label:MyLabel1 AND NOT label:inbox AND NOT label:MyBadLabel1) That search will show you only messages that: Do have MyLabel1 And do not have label inbox And do not have label MyBadLabel1 The tricks are: to get yourself out of conversation mode! (As @Ruben says above.) to use UPPER CASE for the logic operators (AND NOT will work, and not won't) If you leave "conversation mode" on, you will get confusing results. For example, doing that search above (with conversation mode on), will likely return messages that do NOT match your search. It may be a bit weird. Here's the deal: Conversations are collections of messages that all have the same Subject. When "conversation mode" is on, searches return entire conversations as results. So what should gmail search do if a conversation contains both a message that matches, and a message that does not match your search? You are probably expecting it to return conversations only if all messages in that conversation match. But that is not correct. Instead, Gmail search will return conversations even if only a single message in that conversation matches. So that means that if you do the same search above with "conversation mode" on, the results are likely to include messages that do not match your search!

      I came here looking for a way to exclude certain emails from searches in Gmail. I was trying to make sure some emails that were archived don't show up, and this approach works (but the Boolean operators must be capitalized):

      (label:label_I_want AND NOT label:label_I_dont)

      If the unwanted label msgs are a part of a conversation thread containing the wanted msgs, then I'll need to turn this off first:

      Go to the main Settings page, look for the “Conversation View” section, select the option to turn it off, and save changes. If you change your mind, you can always go back. source

  2. Aug 2022
    1. The unary plus operator (+) precedes its operand and converts it into a number. If it fails to convert the operand into a number, then it returns NaN. The unary (-) operator converts the operand into a number and negates it.

      an alternative to !!, in order to convert null, empty strings, boolean values into 0 or 1.

  3. Feb 2022
  4. Jun 2021
  5. Feb 2021
  6. Jan 2020