SOLVED
Using 'not equals' and 'AND' is giving a result like 'OR'
Options
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Mute
- Printer Friendly Page
hope_sch
5 - Atom
‎03-13-2019
12:18 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Hello,
My data set includes rows from 2018 March to 2019 March. I'm using a filter like this:
[Year] != "2019" AND [Month] != "3"
I expected this to only exclude rows with Year=2019 and Month=3. Instead, it excludes all rows where Month=3 (for both 2019 and 2018) and all rows where Year=2019 (for January, February, and March).
Is there an alternative to my filter expression?
Also, I'd like to understand why AND/&& is behaving like an OR.
Thank you,
Hope
Solved! Go to Solution.
Labels:
- Labels:
- Expression
3 REPLIES 3
17 - Castor
‎03-13-2019
01:08 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
‎03-13-2019
01:19 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Ah, this worked! Thank you so much!
17 - Castor
‎03-13-2019
01:29 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
!([Field1] = 2019 AND [Field2] = 3)
This would work too.
When you are negating you have to be very careful how you do it. Set theory can be tricky.
Cheers,
