I'm trying to find all users except for users with an id that is a member of an array exclude_ids
Here's what I have:
User.where("id != ?", exclude_ids)
This only works when exclude_ids has only 1 element. If it has more than one element, I get
this error:
ActiveRecord::StatementInvalid: SQLite3::SQLException: near ",": syntax error: SELECT "users".* FROM "users" WHERE (id != 1,2)
I'd appreciate any help.