Combining whereIn and whereNotIn in same field #3220
Unanswered
masterbater
asked this question in
General
Replies: 1 comment
-
I just added database assertions just to be safe, but please do answer if you have time, I'm curious with the behavior, specially in the native query $in and $nin |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Is this generally safe or I will just do the exclusion processing in filters or pluck and then do another query?
I did test it and the behavior is expected, but I just want to make sure if its generally safe and wont cause issue especially If I want to make sure that byPermissionEngineer should be always applied first. I preferred to do this if its safe since if the User Model has millions of data and one database query could be performant, instead of chunking, extracting ids and do another query or filtering.
Beta Was this translation helpful? Give feedback.
All reactions