aboutsummaryrefslogtreecommitdiffstats
path: root/activerecord/lib/active_record/association_preload.rb
Commit message (Collapse)AuthorAgeFilesLines
* Revert "porting 066518295032a8e3f3468737337b8c8299442867 to master. Thanks ↵Aaron Patterson2010-09-281-1/+1
| | | | | | Marcelo Giorgi" This reverts commit 9eca11a4a564f44675cca951216e917b8f610eab.
* porting 066518295032a8e3f3468737337b8c8299442867 to master. Thanks Marcelo ↵Aaron Patterson2010-09-281-1/+1
| | | | Giorgi
* Prevent shadowing outer local variable.Emilio Tagua2010-09-271-3/+3
|
* remove more codesAaron Patterson2010-09-211-6/+4
|
* deleting more codeAaron Patterson2010-09-211-4/+1
|
* use each properly to avoid splatting a variableAaron Patterson2010-09-211-2/+1
|
* deleting repeated codesAaron Patterson2010-09-211-13/+10
|
* we should mark sql strings as sql literalsAaron Patterson2010-08-231-1/+1
|
* removing unused codeAaron Patterson2010-08-221-3/+1
|
* Deletes trailing whitespaces (over text files only find * -type f -exec sed ↵Santiago Pastorino2010-08-141-4/+4
| | | | 's/[ \t]*$//' -i {} \;)
* ensuring that documentation does not exceed 100 columnsNeeraj Singh2010-08-011-7/+9
|
* eagerly loaded association records should respect default_scope [#2931 ↵Subba Rao Pasupuleti2010-07-211-1/+1
| | | | | | state:resolved] Signed-off-by: José Valim <jose.valim@gmail.com>
* Removed warnings when a variable is shadowedŁukasz Strzałkowski2010-07-191-2/+2
|
* Eager loading :through associations will join the :source model if there are ↵Grant Ammons2010-07-081-1/+6
| | | | | | :conditions. [#2362 state:resolved] Signed-off-by: José Valim <jose.valim@gmail.com>
* edit pass: the names of Rails components have a space, ie, "Active Record", ↵Xavier Noria2010-06-141-6/+6
| | | | not "ActiveRecord"
* refactor evals and adds some __FILE__ and __LINE__Santiago Pastorino2010-05-201-1/+1
| | | | Signed-off-by: José Valim <jose.valim@gmail.com>
* Dont try to load the record from the db if preloading didn't find anythingPratik Naik2010-03-311-0/+5
|
* Fix honoring :primary_key option when joining or eager loading a belongs_to ↵Ernie Miller2010-03-291-1/+1
| | | | | | | | association [#765 state:committed] Signed-off-by: Jeremy Kemper <jeremy@bitsweat.net>
* no more warning interpreted as argument prefix on association_preload.rbSantiago Pastorino2010-02-261-1/+1
|
* Use unscoped instead of with_exclusive_scope for preloadingPratik Naik2010-01-201-14/+13
|
* Use new finder methods for association preloadingPratik Naik2010-01-161-17/+16
|
* Ruby 1.9.2: avoid #flattenJeremy Kemper2009-11-131-8/+12
|
* Merge docrailsPratik Naik2009-07-251-2/+2
|
* Break up DependencyModule's dual function of providing a "depend_on" DSL and ↵Joshua Peek2009-05-281-1/+1
| | | | "included" block DSL into separate modules. But, unify both approaches under AS::Concern.
* Use DependencyModule for included hooks in ActiveRecordBryan Helmkamp2009-05-111-3/+1
|
* honour inverse_of when preloading associationsFrederick Cheung2009-05-101-1/+3
| | | | Signed-off-by: Michael Koziarski <michael@koziarski.com>
* Fix :include of has_one with :primary_key optionFrederick Cheung2008-12-261-1/+1
|
* Fix :include of has_many associations with :primary_key optionFrederick Cheung2008-12-261-1/+1
|
* Preload uses exclusive scope [#643 state:resolved]Frederick Cheung2008-12-261-13/+18
| | | | | | | | | With self referential associations, the scope for the the top level should not affect fetching of associations, for example when doing Person.male.find :all, :include => :friends we should load all of the friends for each male, not just the male friends.
* Association preloading no longer stops if it hits a nil object [#1630 ↵Pivotal Labs2008-12-261-2/+2
| | | | | | state:resolved] Signed-off-by: Frederick Cheung <frederick.cheung@gmail.com>
* Fix preloading of has_one :through associations on belongs_to [#1507 ↵Matt Jones2008-12-181-3/+12
| | | | | | state:resolved] Signed-off-by: Frederick Cheung <frederick.cheung@gmail.com>
* Fix preloading of belongs_to with null foreign key generating useless query ↵Frederick Cheung2008-12-181-0/+1
| | | | [#1027 state:resolved]
* Removed extra 'as' in :joins clause for habtm preloadingFoliosus2008-12-011-1/+1
| | | | | | Signed-off-by: Michael Koziarski <michael@koziarski.com> [#1405 state:committed]
* Remove redundant uniqFrederick Cheung2008-11-111-1/+1
|
* explicitly including child associations that are also included in the parent ↵Will Bryant2008-10-101-0/+3
| | | | | | | association definition should not result in double records in the collection/double loads (#1110) Signed-off-by: Michael Koziarski <michael@koziarski.com> [#1110 state:committed]
* Merge docrailsPratik Naik2008-10-051-3/+87
|
* Remove HasManyAssociationStrategy and move the logic to ↵Pratik Naik2008-10-041-26/+4
| | | | ActiveRecord::Reflection::ThroughReflection.
* Fix has_many :through when the source is a belongs_to association. [#323 ↵Zach Dennis2008-10-041-10/+34
| | | | | | state:resolved] Signed-off-by: Pratik Naik <pratiknaik@gmail.com>
* fix eager loading's :condition sanitizing expanding against the wrong tableWill Bryant2008-09-291-5/+5
| | | | Signed-off-by: Michael Koziarski <michael@koziarski.com>
* fixed association preloading to use = instead of IN when there's only one recordrsl2008-09-101-5/+8
| | | | | | [#1013 state:committed] Signed-off-by: Jeremy Kemper <jeremy@bitsweat.net>
* Fix preloading of has_one through associationsFrederick Cheung2008-08-251-6/+2
| | | | | | [#903 state:resolved] Signed-off-by: Jeremy Kemper <jeremy@bitsweat.net>
* Make sure association preloading works with full STI class name [#465 ↵Joachim Garth2008-07-181-1/+1
| | | | | | state:Resolved] Signed-off-by: Pratik Naik <pratiknaik@gmail.com>
* Merge with docrails.Pratik Naik2008-07-161-1/+1
|
* Fix integer quoting issues in association preload. [#602 state:resolved]Tiago Macedo2008-07-141-3/+12
| | | | Signed-off-by: Pratik Naik <pratiknaik@gmail.com>
* Fixed non-standard SQL generated by preloading has_and_belongs_to_many ↵Antonio Cangiano2008-06-111-2/+2
| | | | association
* When preloading group by reflection rather than by class [#125 state:resolved]Frederick Cheung2008-05-111-6/+6
| | | | | | | | This avoids extra queries when several subclasses inherit the association from their parent class, while still coping with subclasses redefining associations. Signed-off-by: Pratik Naik <pratiknaik@gmail.com>
* Ensure hm:t preloading honours reflection options. [#137 state:resolved]Frederick Cheung2008-05-111-5/+6
| | | | Signed-off-by: Pratik Naik <pratiknaik@gmail.com>
* Ensure correct record is returned when preloading has_one where more than ↵Frederick Cheung2008-05-061-1/+6
| | | | | | | one row exists Signed-off-by: Michael Koziarski <michael@koziarski.com> [#73 state:closed]
* Fixed AssociationsPreload such that it doesnt require foreign keys to be ↵David Heinemeier Hansson2008-04-301-11/+15
| | | | integers (fcheung) [#33 state:resolved]
* Ensure table names are quoted by the association preloading code.Frederick Cheung2008-04-261-9/+7
| | | | | | [#45 state:resolved] Signed-off-by: Michael Koziarski <michael@koziarski.com>