Everything that's inserted into placeholders (the ? above) is escaped - so characters like ' will not break the SQL quoting and allow mischief. Modern Rails versions will even use prepared statements to do this, if your DB adapter supports them.
Your colleague may have been thinking of the (similar but NOT SECURE) form:
scope :with_name_plus_HAX, lambda { |name| where("LOWER(name) LIKE '#{name}'") }
Here the variable is manually interpolated, and will NOT get any escaping. DON'T DO THIS. :)
--Matt Jones