Commit message (Collapse) | Author | Age | Files | Lines | |
---|---|---|---|---|---|
* | remove deprecated implicit join references. | Yves Senn | 2013-06-29 | 1 | -15/+5 |
| | |||||
* | Remove depreacted finders | Łukasz Strzałkowski | 2013-06-28 | 1 | -2/+2 |
| | | | | They were deprecated in 4.0, planned to remove in 4.1 | ||||
* | Make test name descriptive and add reference to original regression commit | Vipul A M | 2013-06-15 | 1 | -1/+2 |
| | |||||
* | has_many through obeys order on through association | Neeraj Singh | 2013-04-04 | 1 | -1/+1 |
| | | | | fixes #10016 | ||||
* | test-case to prevent resetting associations when preloading twice. | Yves Senn | 2013-03-22 | 1 | -0/+7 |
| | | | | | | | Conflicts: activerecord/lib/active_record/associations/preloader/through_association.rb activerecord/test/cases/associations/eager_test.rb | ||||
* | Merge pull request #9782 from vipulnsward/change_from_each_to_each_key_habtm | Rafael Mendonça França | 2013-03-18 | 1 | -2/+2 |
|\ | | | | | Change from each to each_value;drop assignment in habtm | ||||
| * | 1. Change from each to each_value since we did not use key | Vipul A M | 2013-03-19 | 1 | -2/+2 |
| | | | | | | | | 2. drop assignment of value to sum in test | ||||
* | | fix typos in AR. lots of them. | Vipul A M | 2013-03-19 | 1 | -1/+1 |
|/ | |||||
* | Expand order(:symbol) to "table".symbol to prevent broken queries on PG. | Yves Senn | 2013-02-25 | 1 | -1/+6 |
| | | | | | | | | | | Fixes #9275. When `#order` is called with a Symbol this patch will prepend the quoted_table_name. Before the postgresql adapter failed to build queries containg a join and an order with a symbol. This expansion happens for all adapters. | ||||
* | don't apply invalid ordering when preloading hmt associations. | Yves Senn | 2013-02-24 | 1 | -0/+5 |
| | | | | | | | | | | | | | | | closes #8663. When preloading a hmt association there two possible scenarios: 1.) preload with 2 queries: first hm association, then hmt with id IN () 2.) preload with join: hmt association is loaded with a join on the hm association The bug was happening in scenario 1.) with a normal order clause on the hmt association. The ordering was also applied when loading the hm association, which resulted in the error. This patch only applies the ordering the the hm-relation if we are performing a join (2). Otherwise the order will only appear in the second query (1). | ||||
* | don't cache invalid subsets when preloading hmt associations. | Yves Senn | 2013-02-14 | 1 | -0/+6 |
| | | | | closes #8423. | ||||
* | Merge pull request #8568 from inossidabile/fix-in_clause_length | Jon Leighton | 2013-01-11 | 1 | -7/+7 |
|\ | | | | | Correct source for in_clause_length for eager loading (Fix for #8474) | ||||
| * | Eager loading made to use relation's in_clause_length instead of host's one ↵ | Boris Staal | 2012-12-20 | 1 | -7/+7 |
| | | | | | | | | (fixes #8474) | ||||
* | | Rename update_attributes method to update, keep update_attributes as an alias | Amparo Luna + Guillermo Iguaran | 2013-01-03 | 1 | -3/+4 |
|/ | |||||
* | Do not instantiate intermediate AR objects when eager loading. | Yves Senn | 2012-12-04 | 1 | -0/+6 |
| | | | | Closes #3313 | ||||
* | Remove not used variable warnigns | Carlos Antonio da Silva | 2012-12-01 | 1 | -4/+4 |
| | |||||
* | Add a test to make sure preloading properly merges association and default ↵ | Pratik Naik | 2012-08-28 | 1 | -0/+12 |
| | | | | scope conditions | ||||
* | Deprecate ActiveRecord::Base.scoped. | Jon Leighton | 2012-07-27 | 1 | -114/+114 |
| | | | | | | | It doesn't serve much purpose now that ActiveRecord::Base.all returns a Relation. The code is moved to active_record_deprecated_finders. | ||||
* | ActiveRecord::Base.all returns a Relation. | Jon Leighton | 2012-07-27 | 1 | -76/+76 |
| | | | | | | | | | | | Previously it returned an Array. If you want an array, call e.g. `Post.to_a` rather than `Post.all`. This is more explicit. In most cases this should not break existing code, since Relations use method_missing to delegate unknown methods to #to_a anyway. | ||||
* | No need to cache table metadata in advance now that #6683 was merged. | Rafael Mendonça França | 2012-06-11 | 1 | -11/+0 |
| | |||||
* | Merge pull request #6492 from pmahoney/fair-connection-pool2 | Rafael Mendonça França | 2012-06-11 | 1 | -0/+4 |
|\ | | | | | | | | | | | | | Fair connection pool2 Conflicts: activerecord/test/cases/associations/eager_test.rb | ||||
| * | Cache metadata in advance to avoid extra sql statements while testing. | Yasuo Honda | 2012-05-25 | 1 | -0/+7 |
| | | | | | | | | | | Reason: If metadata is not cached extra sql statements will be executed, which causes failures tests with assert_queries(). | ||||
* | | Fix fragile #assert_queries implementation and usages. | Steve Jorgensen | 2012-06-09 | 1 | -2/+0 |
|/ | | | | | | | | | Several tests that passed when run in the order they are loaded by rake test were failing when run in different sequences due to problems with the implementation of assert_queries and assert_no_queries as well as incorrect assumptions made about how many queries might be executed by a database adapter in various cases. | ||||
* | CollectionProxy < Relation | Jon Leighton | 2012-05-11 | 1 | -1/+1 |
| | | | | | | | | | | | | | | | | | | | | | This helps bring the interfaces of CollectionProxy and Relation closer together, and reduces the delegation backflips we need to perform. For example, first_or_create is defined thus: class ActiveRecord::Relation def first_or_create(...) first || create(...) end end If CollectionProxy < Relation, then post.comments.first_or_create will hit the association's #create method which will actually add the new record to the association, just as post.comments.create would. With the previous delegation, post.comments.first_or_create expands to post.comments.scoped.first_or_create, where post.comments.scoped has no knowledge of the association. | ||||
* | remove deprecated calls | Jon Leighton | 2012-04-27 | 1 | -46/+46 |
| | |||||
* | more deprecations manually fixed | Jon Leighton | 2012-04-27 | 1 | -31/+31 |
| | |||||
* | find and replace deprecated keys | Jon Leighton | 2012-04-27 | 1 | -63/+63 |
| | |||||
* | %s/find(:\(first\|last\|all\), \([^()]*\))/scoped(\2).\1/gcI amongst other ↵ | Jon Leighton | 2012-04-27 | 1 | -79/+79 |
| | | | | things | ||||
* | remove calls to find(:first), find(:last) and find(:all) | Jon Leighton | 2012-04-26 | 1 | -2/+2 |
| | |||||
* | remove deprecate #calculate calls | Jon Leighton | 2012-04-26 | 1 | -2/+2 |
| | |||||
* | remove tests for #with_scope (it's now deprecated) | Jon Leighton | 2012-04-25 | 1 | -33/+0 |
| | |||||
* | fix tests | Jon Leighton | 2012-04-13 | 1 | -62/+61 |
| | |||||
* | Adds test to check that circular preloading does not modify Model.unscoped ↵ | Benedikt Deicke | 2012-04-03 | 1 | -0/+6 |
| | | | | (as described in #5667) | ||||
* | Fix #5667. Preloading should ignore scoping. | Jon Leighton | 2012-03-30 | 1 | -0/+11 |
| | |||||
* | Remove IdentityMap | Carlos Antonio da Silva | 2012-03-13 | 1 | -10/+10 |
| | |||||
* | Deprecate inferred JOINs with includes + SQL snippets. | Jon Leighton | 2012-01-16 | 1 | -27/+94 |
| | | | | | | See the CHANGELOG for details. Fixes #950. | ||||
* | Revert "Deprecate implicit eager loading. Closes #950." | Jon Leighton | 2012-01-16 | 1 | -42/+42 |
| | | | | This reverts commit c99d507fccca2e9e4d12e49b4387e007c5481ae9. | ||||
* | Deprecate implicit eager loading. Closes #950. | Jon Leighton | 2011-12-29 | 1 | -42/+42 |
| | |||||
* | More tests deep including through habtm | Arun Agrawal | 2011-12-21 | 1 | -0/+7 |
| | | | fixes #3183 | ||||
* | reintroduce patch from #726 to handle nested eager loading via associations | Jay Levitt | 2011-11-30 | 1 | -0/+35 |
| | |||||
* | ActiveRecord: Fix eager loading so that giving a blank order clause ↵ | Elliot Winkler | 2011-07-18 | 1 | -0/+12 |
| | | | | generates valid SQL | ||||
* | Foo.joins(:bar).includes(:bar) should result in a single query with :bar as ↵ | Jon Leighton | 2011-07-09 | 1 | -0/+8 |
| | | | | a join. Related: #1873. | ||||
* | please use ruby -I lib:test path/to/test.rb, or export RUBY_OPT | Aaron Patterson | 2011-06-06 | 1 | -1/+1 |
| | |||||
* | Refactor Active Record test connection setup. Please see the ↵ | Jon Leighton | 2011-06-04 | 1 | -1/+1 |
| | | | | RUNNING_UNIT_TESTS file for details, but essentially you can now configure things in test/config.yml. You can also run tests directly via the command line, e.g. ruby path/to/test.rb (no rake needed, uses default db connection from test/config.yml). This will help us fix the CI by enabling us to isolate the different Rails versions to different databases. | ||||
* | fixing test for mysql2 | Aaron Patterson | 2011-05-27 | 1 | -5/+2 |
| | |||||
* | adding a test for #1322 | Aaron Patterson | 2011-05-26 | 1 | -0/+15 |
| | |||||
* | Merge pull request #1254 from pixeltrix/ignore-includes-in-through-scope | Jon Leighton | 2011-05-24 | 1 | -0/+6 |
|\ | | | | | Ignore :includes on through associations | ||||
| * | Ignore :includes on through associations | Andrew White | 2011-05-24 | 1 | -0/+6 |
| | | |||||
* | | Failing tests for #1233. | Andrew White | 2011-05-24 | 1 | -0/+40 |
|/ | |||||
* | fixing more test warnings in 1.9.3 | Aaron Patterson | 2011-04-30 | 1 | -2/+2 |
| |