Reputation: 54984
I can't seem to find the answer to this anywhere. I know I can do:
Item.where(:color => 'red')
to get all red items, but how do I get all items whose color is not red?
Upvotes: 3
Views: 111
Reputation: 40277
It's a mix of the old school format and the new Arel format.
Item.where("color != ?", 'red')
Upvotes: 5