Acts_as_list with the scope on boolean field


#1

I have a boolean field in mysql (tinyint) which I want to use as a
scope restriction for acts_as_list

acts_as_list :scope => ‘featured = #{featured}’

however, there is a problem here as when Rails generates SQL query for
this it supplements true/false for #{featured} which raises error in
mysql

As a workaround I created dummy attributes that return 1/0 depending
on featured being true/false.

The question is, whether this is a bug or not? I would assume
ActiveRecord should not use true/false if mysql does not understand
this.