This project is archived and is in readonly mode.
Arel won't let ActiveRecord query against tables that have columns it doesn't know how to handle
-
Jeremy Kemper
- Milestone cleared.
- State changed from new to open
- Assigned user set to Aaron Patterson
- Importance changed from to Low
-
Aaron Patterson
- State changed from open to committed
-
Jason Langenauer
This bug appears to have regressed in Rails 3.0.2 - I'm seeing the same error raised from a PostgreSQL BIGINT column. Stack trace below:
arel (2.0.2) lib/arel/attributes.rb:16:in
for' arel (2.0.2) lib/arel/table.rb:113:inattributes_for' arel (2.0.2) lib/arel/table.rb:112:inmap' arel (2.0.2) lib/arel/table.rb:112:inattributes_for' arel (2.0.2) lib/arel/table.rb:92:incolumns' arel (2.0.2) lib/arel/table.rb:100:in[]' composite_primary_keys (3.0.0.b2) lib/composite_primary_keys/associations.rb:104:inassociation_join' activerecord (3.0.2) lib/active_record/relation/query_methods.rb:242:inbuild_joins' activerecord (3.0.2) lib/active_record/relation/query_methods.rb:237:ineach' activerecord (3.0.2) lib/active_record/relation/query_methods.rb:237:inbuild_joins' activerecord (3.0.2) lib/active_record/relation/query_methods.rb:177:inbuild_arel' activerecord (3.0.2) lib/active_record/relation/query_methods.rb:150:inarel' activerecord (3.0.2) lib/active_record/relation.rb:64:into_a' activerecord (3.0.2) lib/active_record/relation/finder_methods.rb:189:infind_with_associations' activerecord (3.0.2) lib/active_record/relation.rb:64:into_a' activerecord (3.0.2) lib/active_record/relation/finder_methods.rb:143:inall' activerecord (3.0.2) lib/active_record/relation/finder_methods.rb:103:infind' -
Aaron Patterson
Sorry about that. Looks like I didn't add a test, so this got lost. :-(
I've added a test and we'll have a bugfix release of arel shortly.
https://github.com/rails/arel/commit/f0139a16c263ba62e7e45d462a4fff...
