Commit message (Collapse) | Author | Age | Files | Lines | |
---|---|---|---|---|---|
* | Drop unused param `should_be_quoted` to `PostgreSQLColumn#array_to_string` | Vipul A M | 2013-11-17 | 1 | -1/+1 |
| | |||||
* | Merge pull request #12779 from ↵ | Aaron Patterson | 2013-11-15 | 2 | -10/+0 |
|\ | | | | | | | | | dougbarth/dont_swallow_exceptions_during_transactional_statements_in_mysql Don't swallow exceptions in transctional statements | ||||
| * | Don't swallow exceptions in transctional statements | Doug Barth | 2013-11-05 | 2 | -10/+0 |
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The MySQL connection adapater swallows all StandardError exceptions, which includes Mysql::Error and Mysql2::Error. The comment in the exception clause claims errors thrown here indicate that transactions aren't supported by the server but that isn't necessarily true. It's possible the MySQL server has gone away and swallowing a failed commit may let the application return a successful response when the data has not been saved. Also, replication libraries like Galera require that the application handle exceptions thrown at BEGIN/COMMIT. I'm unable to determine what version of MySQL threw an exception for transactional statements. I tried as far back as 3.23.49 with InnoDB disabled but BEGIN & COMMIT statements do not throw an error. If there's a real case for this logic to continue, we could instead push this behavior into a configuration setting. The exception swallowing has been there since the beginning: db045dbbf60b53dbe013ef25554fd013baf88134 | ||||
* | | Merge pull request #12832 from vipulnsward/move_schema_creation | Yves Senn | 2013-11-14 | 2 | -78/+84 |
|\ \ | | | | | | | Move `SchemaCreation` to its own file instead of `AbstractAdapter`. | ||||
| * | | Move `SchemaCreation` to its own file instead of `AbstractAdapter`. | Vipul A M | 2013-11-12 | 2 | -78/+84 |
| | | | |||||
* | | | Remove the unused, undocumented SQLite3Adapter#supports_count_distinct? | Ben Woosley | 2013-11-12 | 1 | -5/+0 |
| | | | | | | | | | | | | This has returned true since 3cc9b5f1, and is not used internally. | ||||
* | | | Drop a sqlite_version check because we only support SQLite 3.6.16 or newer. | Ben Woosley | 2013-11-12 | 2 | -7/+1 |
| | | | | | | | | | Drop some comments that document the implementation rather than the interface. | ||||
* | | | Unifies mysql and mysql2 casting of booleans. | Yves Senn | 2013-11-11 | 2 | -6/+6 |
| | | | |||||
* | | | autoload ChangeColumnDefinition (Fixes #12835) | Anton Kalyaev | 2013-11-11 | 1 | -0/+1 |
| | | | |||||
* | | | Change array check for better aesthetics / reading the code | Carlos Antonio da Silva | 2013-11-09 | 1 | -1/+1 |
| | | | |||||
* | | | Document the bind return | Rafael Mendonça França | 2013-11-09 | 1 | -0/+3 |
| | | | |||||
* | | | Avoid shot circuit return. | Rafael Mendonça França | 2013-11-09 | 1 | -8/+20 |
| | | | | | | | | | | | | This will make the conditional and to code clear | ||||
* | | | Don't use Active Support where we don't need to | Rafael Mendonça França | 2013-11-09 | 3 | -3/+3 |
| | | | |||||
* | | | log bind variables after they were type casted. | Yves Senn | 2013-11-09 | 3 | -10/+16 |
|/ / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The log output used to be confusing in situation where type casting has "unexpected" effects. For example when finding records with a `String`. BEFORE: irb(main):002:0> Event.find("im-no-integer") D, [2013-11-09T11:10:28.998857 #1706] DEBUG -- : Event Load (4.5ms) SELECT "events".* FROM "events" WHERE "events"."id" = $1 LIMIT 1 [["id", "im-no-integer"]] AFTER: irb(main):002:0> Event.find("im-no-integer") D, [2013-11-09T11:10:28.998857 #1706] DEBUG -- : Event Load (4.5ms) SELECT "events".* FROM "events" WHERE "events"."id" = $1 LIMIT 1 [["id", 0]] | ||||
* / | add autoload :TransactionState to fix Marshal.load issues | Jason Ayre | 2013-11-07 | 1 | -0/+1 |
|/ | |||||
* | ask the fixture set for the sql statements | Aaron Patterson | 2013-11-04 | 1 | -1/+5 |
| | |||||
* | fix code typo in `MysqlAdapter` .Closes #12647. | Yves Senn | 2013-10-30 | 1 | -1/+1 |
| | |||||
* | Merge pull request #10664 from aderyabin/docpatch | Yves Senn | 2013-10-29 | 1 | -1/+1 |
|\ | | | | | Fix doc in Postgres database creation [ci skip] | ||||
| * | Fix doc in Postgres database creation | Andrey Deryabin | 2013-06-25 | 1 | -1/+1 |
| | | |||||
* | | Remove confusing generated-code commentary | Jeremy Kemper | 2013-10-28 | 1 | -4/+4 |
| | | |||||
* | | Add a note about ensuring the version is right for the adapter (since you ↵ | David Heinemeier Hansson | 2013-10-27 | 1 | -1/+1 |
| | | | | | | | | might well have specified the right gem, but locked it to too low of a version) | ||||
* | | cast json values on write to be consistent with reading from the db. | Severin Schoepke | 2013-10-25 | 1 | -0/+4 |
| | | | | | | | | See also commit 5ac2341fab689344991b2a4817bd2bc8b3edac9d | ||||
* | | `ActiveRecord::Store` works together with PG `hstore` columns. | Yves Senn | 2013-10-25 | 2 | -0/+12 |
| | | | | | | | | | | | | This is necessary because as of 5ac2341 `hstore` columns are always stored as `Hash` with `String` keys. `ActiveRecord::Store` expected the attribute to be an instance of `HashWithIndifferentAccess`, which led to the bug. | ||||
* | | Escape the parentheses in the default function regexp | Rafael Mendonça França | 2013-10-21 | 1 | -1/+1 |
| | | | | | | | | | | | | | | This is causing every default value in PostreSQL database to being handled as default function. Fixes #12581 | ||||
* | | Remove `default_primary_key_type` and extract contains of ↵ | Vipul A M | 2013-10-14 | 1 | -18/+16 |
| | | | | | | | | `native_database_types` to a constant since they aren't conditional now in SQLite3Adapter. Makes it more like other adapters. | ||||
* | | Merge pull request #11833 from vipulnsward/remove_autoincrement | Rafael Mendonça França | 2013-10-14 | 1 | -10/+1 |
|\ \ | | | | | | | Remove sqlite specific`supports_autoincrement?` which defaults to true | ||||
| * | | Remove sqlite specific`supports_autoincrement?` which always defaults to true | Vipul A M | 2013-08-10 | 1 | -10/+1 |
| | | | |||||
* | | | Extract a function to determine if the default value is a function | Rafael Mendonça França | 2013-10-14 | 1 | -1/+5 |
| | | | |||||
* | | | Push default_function to superclass to avoid method check | Rafael Mendonça França | 2013-10-14 | 2 | -14/+17 |
| | | | |||||
* | | | log the statement name along with the SQL | Aaron Patterson | 2013-10-04 | 2 | -6/+7 |
| | | | |||||
* | | | log every sql statement, even when they error | Aaron Patterson | 2013-10-04 | 1 | -25/+25 |
| | | | |||||
* | | | prepare the statement inside the begin / rescue block | Aaron Patterson | 2013-10-04 | 1 | -4/+4 |
| | | | |||||
* | | | wrap logging around the actual query call itself. | Aaron Patterson | 2013-10-04 | 2 | -50/+50 |
| | | | | | | | | | | | | This is to be consistent with the way the mysql2 adapter times queries | ||||
* | | | extract adapter savepoint implementations into `abstract/savepoints.rb`. | Yves Senn | 2013-09-30 | 6 | -46/+27 |
| | | | |||||
* | | | change the savepoint interface to allow passing the name. | Yves Senn | 2013-09-30 | 4 | -21/+21 |
| | | | |||||
* | | | Fixed issue #12327 | Marc Lennox | 2013-09-27 | 1 | -2/+2 |
| | | | |||||
* | | | ActiveRecord::ConnectionAdapters::Column.string_to_time method respects ↵ | kennyj | 2013-09-25 | 1 | -3/+11 |
| | | | | | | | | | | | | string with timezone. Closes #12278. | ||||
* | | | Merge pull request #11382 from kennyj/fix_10751-2 | Rafael Mendonça França | 2013-09-22 | 1 | -3/+6 |
|\ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | Dump UUID default functions to schema.rb [2nd version]. Fixes #10751. Conflicts: activerecord/CHANGELOG.md | ||||
| * | | | Migration dump UUID default functions to schema.rb. Fixes #10751. | kennyj | 2013-07-10 | 1 | -3/+6 |
| | | | | |||||
* | | | | Disable prepared statements in the unprepared_statement block | Rafael Mendonça França | 2013-09-12 | 1 | -2/+3 |
| | | | | |||||
* | | | | Fix inverted conditional | Rafael Mendonça França | 2013-09-11 | 1 | -1/+1 |
| | | | | | | | | | | | | | | | | Oops, I should had run the tests | ||||
* | | | | Remove invalid comment | Rafael Mendonça França | 2013-09-11 | 1 | -4/+0 |
| | | | | | | | | | | | | | | | | This is not valid anymore after 08477a651648ba4417ded128aa37b9ae0dcbc9ce | ||||
* | | | | Check if the SQL is not a prepared statement | Rafael Mendonça França | 2013-09-11 | 8 | -7/+15 |
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When the adapter is with prepared statement disabled and the binds array is not empty the connection adapter will try to set the binds values and will fail. Now we are checking if the adapter has the prepared statement disabled. Fixes #12023 | ||||
* | | | | Revert "Do not dup the binds when visiting the AST" | Rafael Mendonça França + Kassio Borges | 2013-08-31 | 2 | -2/+3 |
| | | | | | | | | | | | | | | | | | | | | | | | | This reverts commit 71ff7d9c6592b93e2c810a1f464943dd7bd02c7f. Reason: I need to check with @jeremy if we can do this. | ||||
* | | | | Do not dup the binds when visiting the AST | Rafael Mendonça França | 2013-08-31 | 2 | -3/+2 |
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | The visitor have to consume the bind parameters to make the statements work when the prepared statement option is disabled. Fixes #12023 | ||||
* | | | | Perf: fields in pg gem causes an allocation, cache it | Sam | 2013-08-27 | 1 | -2/+3 |
| | | | | |||||
* | | | | Merge pull request #11827 from vipulnsward/remove_extra_case | Santiago Pastorino | 2013-08-26 | 1 | -1/+0 |
|\ \ \ \ | | | | | | | | | | | Remove extra case. | ||||
| * | | | | Remove extra case. | Vipul A M | 2013-08-10 | 1 | -1/+0 |
| | |/ / | |/| | | |||||
* | | | | PG adapter deals with negative money values formatted with parenthesis. | Yves Senn | 2013-08-26 | 1 | -0/+5 |
| | | | | | | | | | | | | | | | | Closes #11899. | ||||
* | | | | Use infinity const | Konstantin Shabanov | 2013-08-22 | 1 | -2/+2 |
| | | | |