> response was roughly like "We might change this in Rails 4" and "$affected_lib should fix it on its side"[1]
[1] https://twitter.com/joernchen/status/298836052410519552
> SELECT * FROM tbl_name WHERE str_col=1;
add index please
SELECT * FROM user WHERE "string" = 0;
will indeed match all users, but
SELECT * FROM user WHERE token = 0;
will not. (Presuming the token is stored in a table column)
User.find_by_reset_password_token(0)
User Load (0.8ms) SELECT `users`.* FROM `users` WHERE `users`.`reset_password_token` = 0 LIMIT 1 => #<User id: 1,[...]
SELECT * FROM users where reset_token = 0;
SELECT * FROM users where reset_token = 1;
SELECT * FROM users where reset_token = 123;
> response was roughly like "We might change this in Rails 4" and "$affected_lib should fix it on its side"[1]
[1] https://twitter.com/joernchen/status/298836052410519552