aboutsummaryrefslogtreecommitdiffstats
path: root/activerecord/lib/active_record/connection_adapters/abstract
Commit message (Collapse)AuthorAgeFilesLines
* Remove being/number methods from transaction classArthur Neves2014-07-311-27/+8
|
* Remove @state.parent assignment on commitArthur Neves2014-07-291-2/+1
| | | | | | | | | This piece of code was introduced on 67d8bb963d5d51fc644d6b1ca20164efb4cee6d7 , which was calling `committed?` in the `transaction_state` before calling the `committed!` method. However on 7386ffc781fca07a0c656db49fdb54678caef809, the `committed?` check was removed and replaced by a `finalized?`, which only checks if the state is not nil. Thus we can remove that line.
* Extract the transaction class to a local variableRafael Mendonça França2014-07-281-6/+2
|
* savepoint_name should return nil for non-savepoint transactionsArthur Neves2014-07-281-1/+6
| | | | Also add test to assets the savepoint name
* Transactions refactoringArthur Neves2014-07-282-38/+64
| | | | | | | Add a transaction manager per connection, so it can controls the connection responsibilities. Delegate transaction methods to transaction_manager
* Remove finishing? method from transaction.Arthur Neves2014-07-241-23/+10
| | | | | | | | | | The finishing variable on the transaction object was a work-around for the savepoint name, so after a rollback/commit the savepoint could be released with the previous name. related: 9296e6939bcc786149a07dac334267c4035b623a 60c88e64e26682a954f7c8cd6669d409ffffcc8b
* Merge pull request #16231 from Envek/type_in_referencesYves Senn2014-07-222-4/+25
|\ | | | | | | | | | | * Allow to specify a type for foreign key column in migrations * unified the docs * some cleanup in CHANGELOG
| * Allow to specify a type for foreign key column in migrationsAndrey Novikov2014-07-222-2/+10
|/ | | | [Andrey Novikov & Łukasz Sarnacki]
* Change back occurrences of SQLite(3) to sqlite3 when referring to theZachary Scott2014-07-061-1/+1
| | | | adapter, fixed from #16057 [ci skip]
* [ci skip] /sqlite/i --> SQLiteAkshay Vishnoi2014-07-061-1/+1
|
* Always pass a column with a type object to quoteSean Griffin2014-06-283-13/+8
| | | | | | | | The only case where we got a column that was not `nil`, but did not respond to `cast_type` was when type casting the default value during schema creation. We can look up the cast type, and add that object to the column definition. Will allow us to consistently rely on the type objects for type casting in all directions.
* Add nodoc to internal class [ci skip]Rafael Mendonça França2014-06-261-1/+1
|
* fk: add docsYves Senn2014-06-261-0/+58
|
* fk: review corrections: indent, visibility, syntax, wording.Yves Senn2014-06-262-26/+27
|
* fk: use random digest namesYves Senn2014-06-263-10/+23
| | | | | | The name of the foreign key is not relevant from a users perspective. Using random names resolves the urge to rename the foreign key when the respective table or column is renamed.
* fk: raise for invalid :on_update / :on_delete valuesYves Senn2014-06-261-3/+8
|
* fk: `add/remove_foreign_key` are noop for adapters that don't support fkYves Senn2014-06-261-0/+4
|
* fk: raise when identifiers are longer than `allowed_index_name_length`.Yves Senn2014-06-261-1/+5
|
* fk: support for on_updateYves Senn2014-06-263-3/+9
|
* fk: rename `dependent` to `on_delete`Yves Senn2014-06-263-9/+8
|
* fk: infere column name from table names.Yves Senn2014-06-261-4/+14
| | | | This allows to create and remove foreign keys without specifying a column.
* fk: support dependent option (:delete, :nullify and :restrict).Yves Senn2014-06-263-2/+18
|
* fk: `:primary_key` option for non-standard pk's.Yves Senn2014-06-261-1/+3
|
* fk: generalize using `AlterTable` and `SchemaCreation`.Yves Senn2014-06-263-7/+56
|
* fk: `foreign_keys`, `add_foreign_key` and `remove_foreign_key` for MySQLYves Senn2014-06-262-0/+21
|
* Remove unused param 'conn' from ConnectionPool#releaseMindaugas Mozūras2014-06-231-3/+3
|
* Don't use column object for type casting in `quoting`Sean Griffin2014-06-181-4/+4
| | | | | | | | | We're never going to be able to use the attribute object here, however, so let's just accept the ugly demeter violation here for now. Remove test cases which were either redundant with other tests in the file, or were actually testing the type objects (which are tested elsewhere)
* Don't type cast the default on the columnSean Griffin2014-06-171-1/+11
| | | | | | | If we want to have type decorators mess with the attribute, but not the column, we need to stop type casting on the column. Where possible, we changed the tests to test the value of `column_defaults`, which is public API. `Column#default` is not.
* /mysql/i -> MySQL, Spell correct in continuation to #15555Akshay Vishnoi2014-06-142-4/+4
|
* Remove unused requireSean Griffin2014-06-111-2/+0
| | | | We're not longer using `ipaddr` in schema dumper
* Change wording of explanation about precision & scale of decimal numbers [ci ↵Prathamesh Sonpatki2014-06-041-2/+2
| | | | skip]
* Refactor quoting of binary data to not be based on the column typeSean Griffin2014-06-031-29/+38
|
* refactor, introduce `Type#type_cast_for_schema` to cast for schema.rbYves Senn2014-05-301-26/+1
| | | | | | | This removes the case statement in `SchemaDumper` and gives every `Type` the possibility to control the SchemaDumper default value output. /cc @sgrif
* Keep closer to other methods that touch @transactionArthur Neves2014-05-281-0/+4
|
* Extract types which don't require additional typecasting to a methodSean Griffin2014-05-261-4/+9
| | | | | Database specific adapters shouldn't need to override `type_cast` to define types which are already in an acceptable state.
* Refactor the type casting of booleans in MySQLSean Griffin2014-05-261-2/+10
|
* Remove checks against `column.type` in abstract adapter quotingSean Griffin2014-05-261-34/+17
| | | | | | The intention is to eventually remove `column` from the arguments list both for `quote` and for `type_cast` entirely. This is the first step to that end.
* Add an interface for type objects to control Ruby => SQLSean Griffin2014-05-261-0/+9
| | | | | Adds the ability to save custom types, which type cast to non-primitive ruby objects.
* Remove special case in schema dumper for decimal without scaleSean Griffin2014-05-231-9/+2
|
* Remove :timestamp column typeSean Griffin2014-05-191-0/+7
| | | | | | | | | | | | The `:timestamp` type for columns is unused. All database adapters treat them as the same database type. All code in `ActiveRecord` which changes its behavior based on the column's type acts the same in both cases. However, when the type is passed to code that checks for the `:datetime` type, but not `:timestamp` (such as XML serialization), the result is unexpected behavior. Existing schema definitions will continue to work, and the `timestamp` type is transparently aliased to `datetime`.
* Make `:index` in migrations work with all column typesMarc Schütz2014-05-181-6/+13
|
* Remove dead test code for unsupported adaptersSean Griffin2014-05-171-9/+0
|
* Convert column name to string only onceKuldeep Aggarwal2014-05-041-1/+2
|
* cache scope building on associationsAaron Patterson2014-04-141-1/+5
| | | | SQL statements for querying associations are now cached
* Merge branch 'master' into adequaterecordAaron Patterson2014-04-141-1/+1
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * master: (70 commits) [ci skip] Added link to ruby-lang.org installation. Use the index on hidden field `collection_check_boxes` respects `:index` option for the hidden filed name. docs, double meaning of `serialize` argument. Closes #14284. Just call read_attribute, no need to use `send`. - Fix lingering reference to `:text` instead of the newer `:plain` - Section references `form_tag` instead of the `form_for` used in the example again, read_attribute is public, so just call it read_attribute is public, so we should just call it Disable assest cache store in docs [ci skip] Make counter cache decrementation on destroy idempotent Write the failing test case for concurrent counter cache [ci skip] Use plain underscore instead of "\_". Update documentation to use Rails.application instead Add a changelog entry for #14546 [ci skip] Move tests for deep_dup and duplicable to object directory Missing 'are' in note - [ci skip] CollectionHelpers now accepts a readonly option Fix a few typos [ci skip] Bundle tzinfo-data on :x64_mingw (64-bit Ruby on Windows). don't bother with an offset if the offset is zero ...
| * please use Ruby, not ActiveSupportAaron Patterson2014-04-111-1/+1
| |
* | working against arel/collector branchAaron Patterson2014-04-091-1/+2
| |
* | fix bind collecting for mysqlAaron Patterson2014-04-091-1/+0
| |
* | add a bind collector, remove the bind visitorAaron Patterson2014-04-091-3/+1
| |
* | use the compile method so we do not have to specify the collectors in this caseAaron Patterson2014-04-091-2/+1
| |