binarylogic / searchlogic

Searchlogic provides object based searching, common named scopes, and other useful tools.
http://rdoc.info/projects/binarylogic/searchlogic
MIT License
1.39k stars 133 forks source link

Insertion of Superfluous Bracket #112

Closed jherdman closed 14 years ago

jherdman commented 14 years ago

Version 2.4.10 is inserting a superfluous bracket in resultant SQL queries thereby causing the queries to raise an exception. We are using PostgreSQL 8.3. The problem is related to changes in SHA: 12c54399518f1569dd854b495b77d444c9509def.

Test cases to come.

jherdman commented 14 years ago

I've narrowed down my issue. The short version of the story is that the SHA: 12c5439 exposed a bug in ActiveRecord itself. This issue can be considered closed as a result.

jherdman commented 14 years ago

The problem has been isolated to ActiveRecord::Consistency#merge_joins_with_singularity. I've submitted a pull request with a patch. The following is a link to the commit that fixes the issue: http://github.com/jherdman/searchlogic/commit/57a486419ab0461ad25ab130b5b976bfe8b2e440