aboutsummaryrefslogtreecommitdiffstats
path: root/activerecord
Commit message (Collapse)AuthorAgeFilesLines
...
| * | | https://github.com/rails/rails/commit/42dd2336b31a8d98776d039a2b9fd7f834156a ↵Vipul A M2016-04-234-4/+43
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 78 changed INSERT INTO versions to run in 1 single query. This breaks for sqlite versions < 3.7.11, which is especially the case on Ubuntu 12.04 LTS, that has SQLite version 3.7.9 as default. So we check for support for multi insert, before performing single query inserts, else fallback to older version of running multiple queries. [Vipul A M & Yasuo Honda]
* | | | Do not attempt to return connection with open transaction to pool (#24610)Sean Griffin2016-04-222-7/+10
|/ / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When the query cache completes, if Active Record is still inside of a transaction, it is because the transaction is meant to be left open above this unit of work (such as transactional fixtures in tests). There were several tests around the behavior of "tests" that were invalid, as tests are not run through the executor. They have been changed to reflect the new behavior, which is closer to what actually occurs in Rails tests. Fixes #23989 Fixes #24491 Close #24500
* | | Merge pull request #24672 from mrkjlchvz/mc-space-bumpRafael França2016-04-211-1/+1
|\ \ \ | | | | | | | | Minor space bump.
| * | | Minor space bump.Mark2016-04-211-1/+1
| | | |
* | | | Revert "add doc for `:type` option of `#create_join_table` [ci skip]"प्रथमेश Sonpatki2016-04-211-2/+0
| | | |
* | | | add doc for `:type` option of `#create_join_table` [ci skip]yuuji.yaginuma2016-04-211-0/+2
| |/ / |/| | | | | | | | Follow up to #24221.
* | | Merge pull request #24221 from gregmolnar/uuidKasper Timm Hansen2016-04-202-2/+10
|\ \ \ | | | | | | | | create_join_table should work with uuid
| * | | add column type option to create_join_table to support uuidGreg Molnar2016-03-172-2/+10
| | | |
* | | | Merge pull request #23557 from ↵Jeremy Daer2016-04-204-32/+55
|\ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | kamipo/dump_indexes_in_create_for_generates_sql_in_one_query Dump indexes in `create_table` for generates SQL in one query
| * | | | Dump indexes in `create_table` for generates SQL in one queryRyuta Kamizono2016-04-204-32/+52
| | | | | | | | | | | | | | | | | | | | | | | | | If the adapter supports indexes in create table, it generates SQL in one query.
* | | | | `undef_method` is not neededRyuta Kamizono2016-04-191-2/+3
|/ / / /
* | | | Fix `test_blank_columns_created_in_block`Ryuta Kamizono2016-04-201-1/+1
| | | | | | | | | | | | | | | | Follow up to 1683410.
* | | | Remove unecessary commentJon Moss2016-04-191-1/+1
| | | |
* | | | Database comments: Treat blank comments as no comment. Don't dump blank ↵Jeremy Daer2016-04-193-57/+98
| | | | | | | | | | | | | | | | comments.
* | | | Define `arel_visitor` method on all adaptersRyuta Kamizono2016-04-204-1/+13
| | | | | | | | | | | | | | | | `Arel::Visitors::VISITORS` was removed at https://github.com/rails/arel/pull/412.
* | | | Remove unused `table_with_autoincrement` tableRyuta Kamizono2016-04-191-4/+0
| | | |
* | | | Merge pull request #24317 from Gaurav2728/unused_set_in_active_recordJeremy Daer2016-04-192-3/+0
|\ \ \ \ | | | | | | | | | | | | | | | connection adapters column, delegation in Active Record have not use …
| * | | | connection adapters column, delegation in Active Record have not use of ↵Gaurav Sharma2016-03-312-3/+0
| | | | | | | | | | | | | | | | | | | | | | | | | ‘set’ found these commits https://github.com/rails/rails/commit/9cc8c6f3730df3d94c81a55be9ee1b7b4ffd29f6, https://github.com/rails/rails/commit/9d79334a1dee67e31222c790e231772deafcaeb8 that also should remove it.
* | | | | Merge pull request #24503 from ↵Jeremy Daer2016-04-191-11/+23
|\ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | prathamesh-sonpatki/add-test-for-warn-on-records-fetched-greater-than Add missing test case for record_fetched_greater_than config
| * | | | | Add missing test case for record_fetched_greater_than configPrathamesh Sonpatki2016-04-111-11/+23
| | | | | | | | | | | | | | | | | | | | | | | | - The negative scenario test case was missing earlier.
* | | | | | Merge pull request #24576 from yahonda/quote_column_name_for_reserved_word_sizeJeremy Daer2016-04-191-1/+1
|\ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | Address ORA-00923 error by quoting a reserved word "SIZE"
| * | | | | | Address ORA-00923 error by quoting a reserved word "SIZE"Yasuo Honda2016-04-161-1/+1
| | | | | | |
* | | | | | | Merge pull request #23497 from kamipo/extract_schema_qualified_nameJeremy Daer2016-04-191-8/+15
|\ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | Extract `extract_schema_qualified_name` method
| * | | | | | | Extract `extract_schema_qualified_name` methodRyuta Kamizono2016-02-051-8/+15
| | | | | | | |
* | | | | | | | Merge pull request #23515 from kamipo/extract_arel_visitorJeremy Daer2016-04-194-28/+12
|\ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | Extract `arel_visitor` and move up to the abstract adapter
| * | | | | | | | Extract `arel_visitor` and move up to the abstract adapterRyuta Kamizono2016-04-044-28/+12
| | |_|_|_|_|_|/ | |/| | | | | |
* | | | | | | | Merge pull request #23523 from kamipo/avoid_truncation_in_uniqueness_validationJeremy Daer2016-04-183-13/+49
|\ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | Avoid a string value truncation in uniqueness validation
| * | | | | | | | Avoid a string value truncation in uniqueness validationRyuta Kamizono2016-02-122-13/+22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In MySQL, PostgreSQL, Oracle and SQLServer, a value over the limit cannot be inserted or updated (See #23522). In SQLite3, a value is inserted or updated regardless of the limit. We should avoid a string value truncation in uniqueness validation.
* | | | | | | | | Merge pull request #23522 from kamipo/add_value_too_long_exception_classJeremy Daer2016-04-185-0/+23
|\ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add `ActiveRecord::ValueTooLong` exception class
| * | | | | | | | | Add `ActiveRecord::ValueTooLong` exception classRyuta Kamizono2016-02-064-0/+18
| | | | | | | | | |
* | | | | | | | | | Merge pull request #24614 from ↵Jeremy Daer2016-04-184-2/+39
|\ \ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | kamipo/foreign_key_respects_table_name_prefix_and_suffix `foreign_key` respects `table_name_prefix` and `table_name_suffix`
| * | | | | | | | | | `foreign_key` respects `table_name_prefix` and `table_name_suffix`Ryuta Kamizono2016-04-193-2/+35
|/ / / / / / / / / /
* | | | | | | | | | Merge pull request #23622 from kamipo/primary_key_should_be_not_nullJeremy Daer2016-04-186-4/+28
|\ \ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Primary key should be `NOT NULL`
| * | | | | | | | | | Primary key should be `NOT NULL`Ryuta Kamizono2016-03-125-4/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Follow up to #18228. In MySQL and PostgreSQL, primary key is to be `NOT NULL` implicitly. But in SQLite it must be specified `NOT NULL` explicitly.
* | | | | | | | | | | Fix isolated test failures due to referencing ↵Jeremy Daer2016-04-183-0/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | ActiveRecord::Tasks::DatabaseAlreadyExists before another test happened to make it available
* | | | | | | | | | | Merge pull request #24607 from vipulnsward/where-clause-frozen-arraySean Griffin2016-04-181-1/+2
|\ \ \ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | Don't create new arrays when trying to compute non_empty_predicates for ast generation
| * | | | | | | | | | | Don't create new arrays when trying to compute non_empty_predicates for ↵Vipul A M2016-04-181-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | where clause predicate. Get a 3-4% improvement in AST generation. Perf compare: https://gist.github.com/vipulnsward/7e4e9ecb157e574002313249a7969c82
* | | | | | | | | | | | Database comments: switch to keyword args for new table optionsJeremy Daer2016-04-1811-69/+79
|/ / / / / / / / / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Switch to keyword args where we can without breaking compat. * Use add_table_options! for :options, too. * Some code polish.
* | | | | | | | | | | Merge pull request #24535 from tomash/association-validate-docsVipul A M2016-04-181-4/+8
|\ \ \ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | Update ActiveRecord associations documentation on :validate option [ci skip]
| * | | | | | | | | | | [ci skip] Update ActiveRecord associations documentation to avoid confusion ↵Tomasz Stachewicz2016-04-181-4/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | with :validate option. Caused by #24532.
* | | | | | | | | | | | Merge pull request #24581 from vipulnsward/add-reference-named-unique-index-testYves Senn2016-04-181-0/+5
|\ \ \ \ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | Add test to verify named unique index, when creating reference via add_reference
| * | | | | | | | | | | | Add test to verify named unique index, when creating reference via add_referenceVipul A M2016-04-161-0/+5
| | |_|_|_|_|_|/ / / / / | |/| | | | | | | | | |
* | | | | | | | | | | | Move CHANGELOG entry about database notices at the top [ci skip]Prathamesh Sonpatki2016-04-181-23/+20
| | | | | | | | | | | |
* | | | | | | | | | | | Merge pull request #24551 from bogdanvlviv/notice_for_tasksJeremy Daer2016-04-176-12/+126
|\ \ \ \ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | Added notice when a database is successfully created or dropped.
| * | | | | | | | | | | | Added notice when a database is successfully created or dropped.bogdanvlviv2016-04-176-12/+126
| | | | | | | | | | | | |
* | | | | | | | | | | | | Merge pull request #22911 from Envek/database_commentsJeremy Daer2016-04-1614-37/+272
|\ \ \ \ \ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add support for specifying comments for tables, columns, and indexes in database itself
| * | | | | | | | | | | | | Add support for specifying comments for tables, columns, and indexes.Andrey Novikov2016-04-1614-37/+278
| | |/ / / / / / / / / / / | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Comments are specified in migrations, stored in database itself (in its schema), and dumped into db/schema.rb file. This allows to generate good documentation and explain columns and tables' purpose to everyone from new developers to database administrators. For PostgreSQL and MySQL only. SQLite does not support comments at the moment. See docs for PostgreSQL: http://www.postgresql.org/docs/current/static/sql-comment.html See docs for MySQL: http://dev.mysql.com/doc/refman/5.7/en/create-table.html
* | | | | | | | | | | | | documentation for add_references index option [ci skip]Vipul A M2016-04-171-1/+10
|\ \ \ \ \ \ \ \ \ \ \ \ \ | |/ / / / / / / / / / / / |/| | | | | | | | | | | | documentation for add_references index option [ci skip]
| * | | | | | | | | | | | [ci skip] docs for add_references index optionAlex Handley2016-04-161-1/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - Add link for finding the addional options for index. - Add example for unique index as this is a common requirement. - Add link in guide for index options.
* | | | | | | | | | | | | Add changelog for #24542Vipul A M2016-04-151-0/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | [ci skip]