Rails 2.1.0 compatability bug
Reported by Zach Dennis | August 6th, 2008 @ 07:03 PM
ar-extensions is breaking the following test Rails 2.1.0:
- HasManyAssociationsTest#testfindwithblankconditions
testfindwithblankconditions(HasManyAssociationsTest):
ActiveRecord::StatementInvalid: Mysql::Error: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ')) AND ( (companies
.type
= 'Client' OR companies
.type
= 'SpecialClient' ' at line 1: SELECT * FROM companies
WHERE (companies
.firm_id = 1 AND ()) AND ( (companies
.type
= 'Client' OR companies
.type
= 'SpecialClient' OR companies
.type
= 'VerySpecialClient' ) ) ORDER BY id
./lib/active_record/connection_adapters/abstract_adapter.rb:147:in `log'
./test/cases/../../lib/active_record/connection_adapters/mysql_adapter.rb:299:in `execute_without_counting'
./test/cases/helper.rb:38:in `execute'
./test/cases/../../lib/active_record/connection_adapters/mysql_adapter.rb:515:in `select'
./lib/active_record/connection_adapters/abstract/database_statements.rb:7:in `select_all_without_query_cache'
./lib/active_record/connection_adapters/abstract/query_cache.rb:61:in `select_all'
./lib/active_record/base.rb:582:in `find_by_sql'
./lib/active_record/base.rb:1341:in `find_every'
./lib/active_record/base.rb:536:in `find'
./lib/active_record/associations/association_collection.rb:47:in `find'
./test/cases/associations/has_many_associations_test.rb:57:in `test_find_with_blank_conditions'
./test/cases/associations/has_many_associations_test.rb:56:in `each'
./test/cases/associations/has_many_associations_test.rb:56:in `test_find_with_blank_conditions'
./lib/../../activesupport/lib/active_support/testing/setup_and_teardown.rb:67:in `__send__'
./lib/../../activesupport/lib/active_support/testing/setup_and_teardown.rb:67:in `run'
Comments and changes to this ticket
-
Zach Dennis August 6th, 2008 @ 07:41 PM
- State changed from new to resolved
Fixed in http://github.com/zdennis/ar-ext...
Please Sign in or create a free account to add a new ticket.
With your very own profile, you can contribute to projects, track your activity, watch tickets, receive and update tickets through your email and much more.
Create your profile
Help contribute to this project by taking a few moments to create your personal profile. Create your profile ยป
ActiveRecord::Extension (aka ar-extensions) is a plugin to extend and
enhance the functionality of ActiveRecord. It starts by adding better
find support for ActiveRecord. It then adds mass data import
capabilities which are highly efficient and lastly it supports to_csv
functionality.
It also introduces a cool concept of creating easily extendable pieces
of ActiveRecord functionality, so developers don't have to understand
ActiveRecord internals or have the fear of breaking ActiveRecord
itself.