sdsykes/slim_scrooge — pull request #26 by bradphilips (2013-04-11 02:22:25+00:00)
Title: Fix for quoted SQL arguments

This is a fix for issue #17 (https://github.com/sdsykes/slim_scrooge/issues/17). It looks like when using PostgreSQL the quote_column_name was quoting the args instead of the column names (http://apidock.com/rails/ActiveRecord/ConnectionAdapters/PostgreSQLAdapter/quote_column_name) This seems to work for me (tested with our barkudo app) but I also didn't have the appropriate setup to be able to run the tests. Let me know if this works with a mysql/other adapter setups as well. Thanks!

BTW, I just tried using v 1.0.13 against a PostgreSQL db. It crashes like this "PG::Error: ERROR: column "1" does not exist
LINE 1: ...erride_fb_pic","users"."id" FROM "users" WHERE "id" IN ("1")"
That "1" is an integer and shouldn't have quotes around it.