- 26 10月, 2016 1 次提交
-
-
由 Ryuta Kamizono 提交于
Follow up to 99cf7558.
-
- 23 10月, 2016 2 次提交
-
-
由 Prathamesh Sonpatki 提交于
- These tests were fixed earlier on master in https://github.com/rails/rails/commit/f13ec72664fd13d33d617103ca964a7592295854. - They started failing in first place due to change in https://github.com/brianmario/mysql2/commit/f14023fcfee9e85e6fc1b0e568048811518f8c23. - They will fail again when the message is changed in mysql2 so let's not rely on the error message.
-
由 Guillermo Iguaran 提交于
-
- 24 9月, 2016 1 次提交
-
-
由 Trung Duc Tran 提交于
Test: JSON attribute value nil can be used in where(attr: nil) Add changelog entry
-
- 14 9月, 2016 2 次提交
-
-
由 Ryuta Kamizono 提交于
All indentation was normalized by rubocop auto-correct at 80e66cc4. But comments was still kept absolute position. This commit aligns comments with method definitions for consistency.
-
由 Yasuo Honda 提交于
-
- 08 9月, 2016 1 次提交
-
-
由 Dylan Thacker-Smith 提交于
By doing `@connection = nil` that means that we need nil checks before it is used anywhere, but we weren't doing those checks. Instead, we get a NoMethodError after using a connection after it fails to reconnect. Neither of the other adapters set @connection to nil, just the mysql2 adapter. By just closing it, we avoid the need to check if we have a connection object and it will produce an appropriate exception when used.
-
- 19 8月, 2016 1 次提交
-
-
由 Ryuta Kamizono 提交于
-
- 16 8月, 2016 1 次提交
-
-
由 Rafael Mendonça França 提交于
Style/SpaceBeforeBlockBraces Style/SpaceInsideBlockBraces Style/SpaceInsideHashLiteralBraces Fix all violations in the repository.
-
- 07 8月, 2016 5 次提交
-
-
由 Xavier Noria 提交于
-
由 Xavier Noria 提交于
-
由 Xavier Noria 提交于
-
由 Xavier Noria 提交于
-
由 Xavier Noria 提交于
The current code base is not uniform. After some discussion, we have chosen to go with double quotes by default.
-
- 05 8月, 2016 1 次提交
-
-
由 David Heinemeier Hansson 提交于
-
- 07 6月, 2016 1 次提交
-
-
由 Ryuta Kamizono 提交于
Fixes #25300.
-
- 31 5月, 2016 1 次提交
-
-
由 Ryuta Kamizono 提交于
Follow up of #20815. ```ruby class CreatePeople < ActiveRecord::Migration[5.0] def change create_table :people do |t| t.integer :int t.bigint :bint t.text :txt t.binary :bin end end end ``` Result. In postgresql and sqlite3 adapters: ```ruby ActiveRecord::Schema.define(version: 20160531141018) do create_table "people", force: :cascade do |t| t.integer "int" t.bigint "bint" t.text "txt" t.binary "bin" end end ``` In mysql2 adapter: ```ruby ActiveRecord::Schema.define(version: 20160531141018) do create_table "people", force: :cascade, options: "ENGINE=InnoDB DEFAULT CHARSET=utf8mb4" do |t| t.integer "int" t.bigint "bint" t.text "txt", limit: 65535 t.binary "bin", limit: 65535 end end ``` After this patch: ```ruby ActiveRecord::Schema.define(version: 20160531141018) do create_table "people", force: :cascade, options: "ENGINE=InnoDB DEFAULT CHARSET=utf8mb4" do |t| t.integer "int" t.bigint "bint" t.text "txt" t.binary "bin" end end ```
-
- 24 5月, 2016 1 次提交
-
-
由 Erol Fornoles 提交于
-
- 21 5月, 2016 1 次提交
-
-
由 Erol Fornoles 提交于
-
- 10 5月, 2016 1 次提交
-
-
由 Ryuta Kamizono 提交于
-
- 04 5月, 2016 1 次提交
-
-
由 Vipul A M 提交于
Fix failing tests
-
- 30 4月, 2016 1 次提交
-
-
由 Ryuta Kamizono 提交于
Refactor of #22911. Signed-off-by: NJeremy Daer <jeremydaer@gmail.com>
-
- 26 4月, 2016 1 次提交
-
-
由 Vipul A M 提交于
Others adapters need to perform a check for validity. Add coverage for mysql2 db type validation
-
- 14 4月, 2016 1 次提交
-
-
由 Sean Griffin 提交于
Previously we were assuming that the only valid types for encoding were arrays and hashes. However, any JSON primitive is an accepted value by both PG and MySQL. This does involve a minor breaking change in the handling of `default` in the schema dumper. This is easily worked around, as passing a hash/array literal would have worked fine in previous versions of Rails. However, because of this, I will not be backporting this to 4.2 or earlier. Fixes #24234
-
- 09 4月, 2016 1 次提交
-
-
由 Jeremy Daer 提交于
We support microsecond datetime precision for MySQL 5.6.4+. MariaDB has supported it since 5.3.0, but even 10.x versions return a compatible version string like `5.5.5-10.1.8-MariaDB-log` which we parse as 5.5.5, before MySQL supported microsecond precision. Specialize our version check to account for MariaDB to fix.
-
- 05 4月, 2016 1 次提交
-
-
由 yui-knk 提交于
Because we define `QUOTED_TRUE` as `"1"` and `QUOTED_FALSE` as `"0"`. And add test cases to ensure this commit does not break current behavior even if the value of `attributes_before_type_cast` is false.
-
- 13 3月, 2016 1 次提交
-
-
由 Ryuta Kamizono 提交于
For keep the default SQL mode.
-
- 11 3月, 2016 1 次提交
-
-
由 Ryuta Kamizono 提交于
Before: ```ruby create_table "big_numbers", force: :cascade do |t| t.integer "bigint_column", limit: 8 end ``` After: ```ruby create_table "big_numbers", force: :cascade do |t| t.bigint "bigint_column" end ```
-
- 29 2月, 2016 2 次提交
-
-
由 Ryuta Kamizono 提交于
Currently `exec_query` raises `NoMethodError` when executing no result queries (`INSERT`, `UPDATE`, `DELETE`, and all DDL) in mysql2 adapter. ``` irb(main):002:0> conn.execute("create table t(a int)") (43.3ms) create table t(a int) => nil irb(main):003:0> conn.execute("insert into t values (1)") (19.3ms) insert into t values (1) => nil irb(main):004:0> conn.exec_query("insert into t values (1)") SQL (28.6ms) insert into t values (1) NoMethodError: undefined method `fields' for nil:NilClass ```
-
由 Ryuta Kamizono 提交于
-
- 22 2月, 2016 1 次提交
-
-
由 Ryuta Kamizono 提交于
Follow up to #13040.
-
- 01 2月, 2016 1 次提交
-
-
由 Ryuta Kamizono 提交于
`initialize_schema_migrations_table` is called in every migrations. https://github.com/rails/rails/blob/v5.0.0.beta1/activerecord/lib/active_record/migration.rb#L1080 https://github.com/rails/rails/blob/v5.0.0.beta1/activerecord/lib/active_record/schema.rb#L51 This means that extra `show variables` is called regardless of the existence of `schema_migrations` table. This change is to avoid extra `show variables` if `schema_migrations` table exists.
-
- 31 1月, 2016 1 次提交
-
-
由 Ryuta Kamizono 提交于
Follow up to #22896.
-
- 22 1月, 2016 1 次提交
-
-
由 schneems 提交于
Mysql has a weird bug where it cannot index a string column of utf8mb4 if it is over a certain character limit. To get compatibility with msql we can add a limit to the key column. 191 characters is a very long key, it seems reasonable to limit across all adapters since using a longer key wouldn't be supported in mysql. Thanks to @kamipo for the original PR and the test refactoring. Conversation: https://github.com/rails/rails/pull/23009#issuecomment-171416629
-
- 04 1月, 2016 1 次提交
-
-
由 Ryuta Kamizono 提交于
-
- 27 12月, 2015 1 次提交
-
-
由 Ryuta Kamizono 提交于
Avoid instanciate `ActiveRecord::Result` and calling `ActiveRecord::Result#hash_rows` for the performance.
-
- 23 12月, 2015 1 次提交
-
-
由 Ryuta Kamizono 提交于
In MySQL 5.7.5 and up, ONLY_FULL_GROUP_BY affects handling of queries that use DISTINCT and ORDER BY. It requires the ORDER BY columns in the select list for distinct queries, and requires that the ORDER BY include the distinct column. See https://dev.mysql.com/doc/refman/5.7/en/group-by-handling.html
-
- 22 12月, 2015 1 次提交
-
-
由 Stephen Blackstone 提交于
-
- 21 12月, 2015 1 次提交
-
-
由 Ryuta Kamizono 提交于
Follow up to #22642.
-
- 18 12月, 2015 1 次提交
-
-
由 Matthew Draper 提交于
-