I would like to use squeel in order to build query like:
SELECT * from `table`
WHERE (`field1`, `field2`)
NOT IN (
(1,"value_a"),
(2,"value_b"),
(3,"value_a"),
...
)
I want to know if there is any way to compare multiple fields with an array via IN
or NOT IN
statement.
Something like this (I am aware that example does not work) would be a nice way to express what I mean:
array = [[1,"value_a"], [2,"value_b"], [3, "value_a"]]
Table.where{ (field1 & filed2).not_in array }
Is something like this possible at all?
Update
I know how to get the same final result using multiple ... & (a != b) & (c != d) & ...
, but that was not what I have asked.