-
-
Notifications
You must be signed in to change notification settings - Fork 827
Closed
Description
Hi,
Using Ruby 1.9.3p0, Rails 3.2.2, MySQL 5.5.20, and Ransack 0.6.0, I'm unable to use '_cont' on an Integer column, while the database natively supports '%like%' queries there.
For the incoming search parameter "members_payments_amount_cont"=>"3" the SQL issued by Ransack is "WHERE (payments.amount LIKE 0)", which is obviously an issue.
If I use "members_payments_amount_eq"=>"3" the SQL is correct as shown here: "WHERE payments.amount = 3"
I suspect this is related to string vs. integer data types and am wondering if the behavior is intended or a bug?
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels