search for: association_preload

Displaying 5 results from an estimated 5 matches for "association_preload".

2009 Feb 02
9
ActiveRecord Unexplainable SystemStackError - Only in WEBrick
...ssing'' /usr/lib/ruby/gems/1.8/gems/activerecord-2.1.0/lib/active_record/ attribute_methods.rb:245:in `method_missing'' /usr/lib/ruby/gems/1.8/gems/activerecord-2.1.0/lib/active_record/ base.rb:2435:in `hash'' /usr/lib/ruby/gems/1.8/gems/activerecord-2.1.0/lib/active_record/ association_preload.rb:13:in `uniq'' /usr/lib/ruby/gems/1.8/gems/activerecord-2.1.0/lib/active_record/ association_preload.rb:13:in `preload_associations'' /usr/lib/ruby/gems/1.8/gems/activerecord-2.1.0/lib/active_record/ base.rb:1343:in `find_every'' /usr/lib/ruby/gems/1.8/gems/activerecord-2....
2008 Nov 06
10
Rails 2.1.2 bug in include on has_many?
...yone run into this? Any ideas? That :include is really useful to me for efficiency. You have a nil object when you didn''t expect it! You might have expected an instance of Array. The error occurred while evaluating nil.each /usr/lib/ruby/gems/1.8/gems/activerecord-2.1.2/lib/active_record/association_preload.rb:74:in `set_association_single_records'' /usr/lib/ruby/gems/1.8/gems/activerecord-2.1.2/lib/active_record/association_preload.rb:67:in `each'' /usr/lib/ruby/gems/1.8/gems/activerecord-2.1.2/lib/active_record/association_preload.rb:67:in `set_association_single_records'' /u...
2010 Dec 09
15
Rails 3 Active Record query returns "undefined method `loaded?' for #<Array:0x126a4c>"
I am getting this error on an rspec test: undefined method `loaded?'' for #<Array:0x126a4c> When I call: Practice.includes("practice_members").all Practice has_many :practice_members PracticeMember belongs_to :practice Practice.all returns: [#<Practice id: 6, name: "Practice One", created_at: "2010-12-09 15:40:46", updated_at: "2010-12-09
2008 Feb 19
1
[CruiseControl] RubyOnRails build 8896 failed
The build failed. CHANGES ------- Revision 8896 committed by bitsweat on 2008-02-19 02:56:05 Don''t assume all records from nested include are of same class. Closes #11154 [acechase] M /trunk/activerecord/lib/active_record/association_preload.rb A /trunk/activerecord/test/cases/associations/eager_load_nested_include_test.rb TEST FAILURES AND ERRORS ----------------------- Name: test_include_query(EagerLoadPolyAssocsTest) Type: Error Message: ActiveRecord::StatementInvalid: PGError: ERROR: syntax error at or near "Engine"...
2009 Oct 08
6
Eager Loading a Relationship That Has No PK/FK
I''m attempting to wrestle an old DB into Rails. This relationship is giving me trouble: class Show < AR::Base has_many :segments end class Segment < AR::Base belongs_to :show has_one :media #this has no PK/FK relation end A Segment is "linked" to Media by Media.name, which is the result of concatenating Segment.name and Segment.part. As I said there are is no