aboutsummaryrefslogtreecommitdiffstats
path: root/activerecord/CHANGELOG.md
Commit message (Collapse)AuthorAgeFilesLines
...
| * | | Expand order(:symbol) to "table".symbol to prevent broken queries on PG.Yves Senn2013-02-251-0/+9
| | |/ | |/| | | | | | | | | | | | | | | | | | | | | | | | | 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.
* | | typoXavier Noria2013-02-251-1/+1
| | |
* | | AR loads activerecord-deprecated_finders, no need to add it to the GemfileXavier Noria2013-02-251-6/+5
| | |
* | | New CHANGELOG entries always on top [ci skip]Rafael Mendonça França2013-02-251-4/+4
| | |
* | | Do not override attributes on `dup` by default scopesHiroshige Umino2013-02-261-0/+4
| | |
* | | Preparing for 4.0.0.beta1 releaseDavid Heinemeier Hansson2013-02-251-1/+1
| | |
* | | some minor AR changelog modifications [ci skip]Yves Senn2013-02-251-3/+7
|/ /
* | Raising an ActiveRecordError when one tries to use .touch(name) on a newwangjohn2013-02-251-0/+11
| | | | | | | | | | object that has not yet been persisted. This behavior follows the precedent set by update_columns.
* | Improve AR changelog [ci skip]Carlos Antonio da Silva2013-02-241-2/+2
| |
* | don't apply invalid ordering when preloading hmt associations.Yves Senn2013-02-241-0/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 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).
* | Merge pull request #9400 from senny/remove_auto_explain_threshold_in_secondsXavier Noria2013-02-241-0/+9
|\ \ | | | | | | remove config.auto_explain_threshold_in_seconds
| * | remove AR auto-explain (config.auto_explain_threshold_in_seconds)Yves Senn2013-02-241-0/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | We discussed that the auto explain feature is rarely used. This PR removes only the automatic explain. You can still display the explain output for any given relation using `ActiveRecord::Relation#explain`. As a side-effect this should also fix the connection problem during asset compilation (#9385). The auto explain initializer in the `ActiveRecord::Railtie` forced a connection.
* | | Do not type cast all the database url values.Rafael Mendonça França2013-02-241-3/+3
|/ / | | | | | | | | | | We should only type cast when we need to use. Related to 4b005fb371c2e7af80df7da63be94509b1db038c
* | multiple actions for :on option with `after_commit` and `after_rollback`Yves Senn2013-02-211-0/+8
| | | | | | | | Closes #988.
* | ActiveRecord -> Active Record [ci skip]Xavier Noria2013-02-201-1/+1
| |
* | removes relation bang methods from the AR changelog [ci skip]Xavier Noria2013-02-201-12/+0
| |
* | puts a lambda around a default scope [ci skip]Xavier Noria2013-02-201-1/+1
| |
* | database.yml -> config/database.yml [ci skip]Xavier Noria2013-02-201-1/+1
| |
* | unify AR changelog entries [ci skip]Yves Senn2013-02-201-4/+4
| |
* | also rename indexes when a table or column is renamedYves Senn2013-02-201-0/+5
| | | | | | | | When a table or a column is renamed related indexes kept their name. This will lead to confusing names. This patch renames related indexes when a column or a table is renamed. Only indexes with names generated by rails will be renamed. Indexes with custom names will not be renamed.
* | moves the new :nsec date format to the Active Support changelog [ci skip]Xavier Noria2013-02-201-6/+1
| |
* | reserve index name chars for internal rails operationsYves Senn2013-02-201-0/+8
| | | | | | | | | | | | | | | | | | | | | | Some adapter (SQLite3) need to perform renaming operations to support the rails DDL. These rename prefixes operate with prefixes. When an index name already uses up the full space provieded by `index_name_length` these internal operations will fail. This patch introduces `allowed_index_name_length` which respects the amount of characters used for internal operations. It will always be <= `index_name_length` and every adapter can define how many characters need to be reserved.
* | Merge pull request #9332 from ↵Rafael Mendonça França2013-02-201-4/+2
|\ \ | | | | | | | | | | | | wangjohn/adding_documentation_to_error_raising_in_query_methods Tests to make sure empty arguments in WhereChain raise errors
| * | Added comments about the check_empty_arguments method which is calledwangjohn2013-02-201-4/+2
| | | | | | | | | | | | | | | for query methods in a where_clause. Also, modified the CHANGELOG entry because it had false information and added tests.
* | | Reduced memory leak problem in transactions by lazily updating AR objects ↵wangjohn2013-02-201-0/+22
|/ / | | | | | | with new transaction state. If AR object has a callback, the callback will be performed immediately (non-lazily) so the transaction still has to keep records with callbacks.
* | descriptive error message when AR adapter was not found. Closes #7313.Yves Senn2013-02-201-1/+6
| |
* | s/revertible/reversible/Xavier Noria2013-02-191-1/+1
| |
* | moves a CHANGELOG entry from AR to APXavier Noria2013-02-191-4/+0
| |
* | small tweaks in the AR CHANGELOGXavier Noria2013-02-191-4/+4
| |
* | Raise an error when query methods have blank arguments, and when blank ↵John J Wang2013-02-191-0/+11
| | | | | | | | arguments are meaningless.
* | Add CHANGELOG entry for 41ff6a10216f48f43605a1f9cd6094765cab750fAndrew White2013-02-171-0/+40
| | | | | | | | [ci skip]
* | don't cache invalid subsets when preloading hmt associations.Yves Senn2013-02-141-0/+22
| | | | | | | | closes #8423.
* | Don't call after_commit when creating through an association and save fails, ↵James Miller2013-02-131-0/+5
| | | | | | | | fixes #5802
* | define Active Record Store accessors in a moduleSergey Nartimov2013-02-111-0/+12
| | | | | | | | | | | | | | | | | | | | | | | | | | Allow store accessors to be overrided like other attribute methods, e.g.: class User < ActiveRecord::Base store :settings, accessors: [ :color, :homepage ], coder: JSON def color super || 'red' end end
* | Update activerecord/CHANGELOG.mdGuillermo Iguaran2013-02-091-1/+1
| |
* | Reverting e170014113 (Change behaviour with empty hash in where clause)Guillermo Iguaran2013-02-081-5/+0
| |
* | Reverting 16f6f25 (Change behaviour with empty array in where clause)Guillermo Iguaran2013-02-081-5/+0
| |
* | Improve changelog entries in ARCarlos Antonio da Silva2013-02-081-5/+6
| | | | | | | | | | | | | | Describe better the changes related to raising errors with empty array/hash values in where clauses. [ci skip]
* | Change behaviour with empty array in where clauserobertomiranda2013-02-081-0/+5
| |
* | Change behaviour with empty hash in where clauserobertomiranda2013-02-081-0/+4
| |
* | active_record: Quote numeric values compared to string columns.Dylan Smith2013-02-071-0/+10
|/
* Add changelog entry for #9203 about schema dumper with db extensionsCarlos Antonio da Silva2013-02-061-0/+5
| | | | [ci skip]
* CHANGELOG reviewRafael Mendonça França2013-01-311-3/+3
|
* DATABASE_URL parsing should turn numeric strings into numeric types, andAaron Stone2013-01-311-0/+12
| | | | | | the strings true and false into boolean types, in order to match how YAML would parse the same values from database.yml and prevent unexpected type errors in the database adapters.
* Refactor to use each_key, remove extra spacesCarlos Antonio da Silva2013-01-281-1/+1
|
* Prevent Relation#merge from collapsing wheres on the RHSJon Leighton2013-01-271-0/+26
| | | | | | | | | | | | | | | | | | | | | | | This caused a bug with the new associations implementation, because now association conditions are represented as Arel nodes internally right up to when the whole thing gets turned to SQL. In Rails 3.2, association conditions get turned to raw SQL early on, which prevents Relation#merge from interfering. The current implementation was buggy when a default_scope existed on the target model, since we would basically end up doing: default_scope.merge(association_scope) If default_scope contained a where(foo: 'a') and association_scope contained a where(foo: 'b').where(foo: 'c') then the merger would see that the same column is representated on both sides of the merge and collapse the wheres to all but the last: where(foo: 'c') Now, the RHS of the merge is left alone. Fixes #8990
* Fix handling of dirty time zone aware attributesLilibeth De La Cruz2013-01-261-0/+28
| | | | | | | | | | | | | | | | | | | | | | | | | | Previously, when `time_zone_aware_attributes` were enabled, after changing a datetime or timestamp attribute and then changing it back to the original value, `changed_attributes` still tracked the attribute as changed. This caused `[attribute]_changed?` and `changed?` methods to return true incorrectly. Example: in_time_zone 'Paris' do order = Order.new original_time = Time.local(2012, 10, 10) order.shipped_at = original_time order.save order.changed? # => false # changing value order.shipped_at = Time.local(2013, 1, 1) order.changed? # => true # reverting to original value order.shipped_at = original_time order.changed? # => false, used to return true end
* `#count` in conjunction with `#uniq` performs distinct count.Yves Senn2013-01-261-0/+9
| | | | closes #6865
* Add postgresql range types supportbUg2013-01-231-0/+19
|
* Added a changelog entry.wangjohn2013-01-201-0/+5
|