aboutsummaryrefslogtreecommitdiffstats
path: root/activerecord
Commit message (Collapse)AuthorAgeFilesLines
* Added missing docs for clear_cache! on adaptersSebastian Martinez2011-04-223-0/+3
|
* Added missing docs for +supports_primary_key?+ on some adaptersSebastian Martinez2011-04-222-0/+2
|
* Added missing docs for +support_migrations?+ on some adaptersSebastian Martinez2011-04-222-0/+2
|
* Have a more connection specific rdoc for +supports_statement_cache?+Sebastian Martinez2011-04-223-6/+6
|
* Removed ON() on distinct commentSebastian Martinez2011-04-221-1/+1
|
* Avoid define_method if possible.José Valim2011-04-192-2/+2
|
* Bring back support for passing a callable object to the default_scope macro. ↵Jon Leighton2011-04-184-0/+52
| | | | You can also just use a block.
* Un-deprecate using 'default_scope' as a macro, but if you are calling the ↵Jon Leighton2011-04-1810-270/+85
| | | | macro multiple times that will give deprecation warnings, and in 3.2 we will simply overwrite the default scope when you call the macro multiple times.
* Fix test_load_save in test/cases/binary_test.rb (thanks @tenderlove for ↵Jon Leighton2011-04-171-2/+1
| | | | actually working out how to fix it)
* Fix test_associate_existing in has_many_through_associations_test on mysql ↵Jon Leighton2011-04-171-1/+1
| | | | and postgresql
* Bring back some bits of documentation for scopes which were removed as part ↵Jon Leighton2011-04-171-1/+29
| | | | of the reversion in 256b363
* Revert "Deprecate defining scopes with a callable (lambda, proc, etc) via ↵Jon Leighton2011-04-176-114/+23
| | | | | | | | | | the scope class method. Just define a class method yourself instead." This reverts commit f0e198bfa1e3f9689e0cde1d194a44027fc90b3c. Conflicts: activerecord/test/models/post.rb
* Bypass IdentityMap in PostgreSQL geometric tests.Jason Weathered2011-04-171-2/+2
| | | | The identity map cache prevents us from seeing the DB formatted strings.
* Return nil from read_attribute(:foo) if 'foo' is not present in the ↵Jon Leighton2011-04-152-2/+3
| | | | @attributes hash, but the _foo method has been defined. This brings the behaviour into line with the 3-0-stable branch and the master branch before 93641ed6c8c684f6b4db02b6c8a22fa9bc7f0eaf (there were previously no assertions about this which is why the change slipped through). Note that actually calling the 'foo' method will still raise an error if the attribute is not present.
* Undo performances regressions I introduced in ↵Jon Leighton2011-04-152-5/+34
| | | | bbe0a507f287c20ab4ae8a244fbfc810665deda5 and add test for an edge case. Add comments to explain the intent of the code.
* Refactor test to avoid hackeryJon Leighton2011-04-151-4/+4
|
* Remove unnecessary code from define_read_method and add assertion to make ↵Jon Leighton2011-04-152-7/+5
| | | | sure the underscored version is actually generated
* sort insert columns for better cache hitsAaron Patterson2011-04-141-1/+1
|
* refactoring inserts to use the same method on the connectionAaron Patterson2011-04-141-21/+16
|
* mimic prepared statements in the exec_insert for mysql2Aaron Patterson2011-04-141-0/+11
|
* mysql type cast should return integers when typecasting true / falseAaron Patterson2011-04-143-0/+57
|
* using the database adapter to typecast before executing prepared statementAaron Patterson2011-04-144-2/+34
|
* inserting big decimals as strings works consistently among dbs, so use ↵Aaron Patterson2011-04-142-2/+2
| | | | string form
* insert statements are prepared, but values are not escaped properlyAaron Patterson2011-04-145-8/+64
|
* adding a type cast method for prepared statementsAaron Patterson2011-04-143-1/+130
|
* Extract the constraint-building for joins in JoinAssociation into a separate ↵Jon Leighton2011-04-141-8/+14
| | | | method to make it easy to change/override (requested by Ernie Miller so that MetaWhere can add to it easily)
* Fixes performance issue introduced in 3.0.6 (issue #6695)Stian Grytøyr2011-04-141-3/+5
|
* do not depend on to_yaml being called, but rather depend on YAML being dumpedAaron Patterson2011-04-132-7/+8
|
* use index based substitution for bind parametersAaron Patterson2011-04-137-10/+10
|
* Remove `#among?` from Active SupportPrem Sichanugrist2011-04-1311-11/+11
| | | | | | After a long list of discussion about the performance problem from using varargs and the reason that we can't find a great pair for it, it would be best to remove support for it for now. It will come back if we can find a good pair for it. For now, Bon Voyage, `#among?`.
* common @jonleighton :bomb:Aaron Patterson2011-04-121-2/+1
|
* Deprecate defining scopes with a callable (lambda, proc, etc) via the scope ↵Jon Leighton2011-04-126-23/+116
| | | | class method. Just define a class method yourself instead.
* ActiveRecord::Base.scopes hash is not neededJon Leighton2011-04-123-29/+4
|
* Evaluate default scopes at the last possible moment in order to avoid ↵Jon Leighton2011-04-1210-33/+67
| | | | problems with default scopes getting included into other scopes and then being unable to remove the default part via unscoped.
* Deprecated support for passing hashes and relations to default_scope, in ↵Jon Leighton2011-04-1217-172/+410
| | | | favour of defining a 'default_scope' class method in the model. See the CHANGELOG for more details.
* Removing the scope-caching which happens on association proxies, because the ↵Jon Leighton2011-04-123-24/+15
| | | | query is already cached by the query cacher. For formalised proof see http://www.youtube.com/watch?v=wDefXLb-FDs
* stop using deprecated methods in arelAaron Patterson2011-04-111-2/+2
|
* Change Object#either? to Object#among? -- thanks to @jamesarosen for the ↵David Heinemeier Hansson2011-04-1211-11/+11
| | | | suggestion!
* remove so many nested if statementsAaron Patterson2011-04-111-9/+11
|
* wrap the pg_get_serial_sequence function and reuse it for the default ↵Aaron Patterson2011-04-112-2/+35
| | | | sequence name
* cache table exists queries in prepared statement cacheAaron Patterson2011-04-111-3/+6
|
* only use the primary_key method, refactor schema and table name parsingAaron Patterson2011-04-111-13/+15
|
* use prepared statements for primary key queriesAaron Patterson2011-04-111-2/+15
|
* last insert id can never be called, so remove that code pathAaron Patterson2011-04-111-11/+3
|
* we know the table and pk, so we can calculate a default sequence nameAaron Patterson2011-04-111-3/+4
|
* always look up pk and sequence unless both are providedAaron Patterson2011-04-111-6/+5
|
* pg does not know the insert_id in advance, so super will never return trueAaron Patterson2011-04-111-13/+10
|
* updating the docco for ActiveRecord::ResultAaron Patterson2011-04-111-2/+2
|
* implement exec_query on mysql2 adapterAaron Patterson2011-04-111-2/+20
|
* make sqlite insert_sql more consistent with other adaptersAaron Patterson2011-04-111-1/+2
|