I want to grab all the users that either have an email as the one supplied or the first and last name. So for example:
users = User.where(:first_name => \
Try this:
users = User.where("(first_name = 'James' and last_name = 'Scott') or email = 'james@gmail.com'")
To interpolate variables:
users = User.where("(first_name = ? and last_name = ?) or email = ?", first_name, last_name, email)