Commit message (Collapse) | Author | Age | Files | Lines | |
---|---|---|---|---|---|
* | Always pass a column with a type object to quote | Sean Griffin | 2014-06-28 | 1 | -0/+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. | ||||
* | rename sequence only if it exists | Abdelkader Boudih | 2014-06-27 | 1 | -3/+3 |
| | |||||
* | fk: review corrections: indent, visibility, syntax, wording. | Yves Senn | 2014-06-26 | 1 | -12/+12 |
| | |||||
* | fk: support for on_update | Yves Senn | 2014-06-26 | 1 | -7/+12 |
| | |||||
* | fk: rename `dependent` to `on_delete` | Yves Senn | 2014-06-26 | 1 | -2/+2 |
| | |||||
* | fk: support dependent option (:delete, :nullify and :restrict). | Yves Senn | 2014-06-26 | 1 | -1/+8 |
| | |||||
* | fk: generalize using `AlterTable` and `SchemaCreation`. | Yves Senn | 2014-06-26 | 1 | -20/+0 |
| | |||||
* | fk: `foreign_keys`, `add_foreign_key` and `remove_foreign_key` for MySQL | Yves Senn | 2014-06-26 | 1 | -7/+0 |
| | |||||
* | fk: add `foreign_keys` for PostgreSQL adapter. | Yves Senn | 2014-06-26 | 1 | -0/+24 |
| | |||||
* | fk: `add_foreign_key` and `remove_foreign_key` for PostgreSQL adapter. | Yves Senn | 2014-06-26 | 1 | -0/+27 |
| | |||||
* | pg, support default values for enum types. Closes #7814. | Yves Senn | 2014-05-30 | 1 | -1/+1 |
| | | | | | This is an intermediate solution. It is related to the refactoring @sgrif is making and will change in the future. | ||||
* | pg, `default_sequence_name` respects schema. Closes #7516. | Yves Senn | 2014-05-30 | 1 | -2/+2 |
| | |||||
* | Merge pull request #11896 from nkondratyev/fix_pg_columns_for_distinct | Yves Senn | 2014-05-30 | 1 | -1/+1 |
|\ | | | | | | | | | | | | | Fixed #columns_for_distinct of postgresql adapter Conflicts: activerecord/CHANGELOG.md | ||||
| * | Fixed `columns_for_distinct` of postgresql adapter | Nikolay Kondratyev | 2013-08-15 | 1 | -1/+1 |
| | | |||||
* | | pg, `reset_pk_sequence!` respects schemas. Closes #14719. | Yves Senn | 2014-05-30 | 1 | -5/+13 |
| | | |||||
* | | pg, `PostgreSQL::Name` to hold schema qualified names. | Yves Senn | 2014-05-30 | 1 | -4/+4 |
| | | |||||
* | | Ensure we always use instances of the adapter specific column class | Sean Griffin | 2014-05-28 | 1 | -1/+5 |
| | | | | | | | | | | | | - Create a consistent API across adapters for building new columns - Use it for custom properties so we don't get `UndefinedMethodError`s in stuff I'm implementing elsewhere. | ||||
* | | remove unwanted `to_sym` call. | Kuldeep Aggarwal | 2014-05-26 | 1 | -1/+1 |
| | | |||||
* | | Move parsing of PG sql strings for defaults out of column | Sean Griffin | 2014-05-23 | 1 | -1/+3 |
| | | |||||
* | | Allow additional arguments to be used during type map lookups | Sean Griffin | 2014-05-22 | 1 | -1/+1 |
| | | | | | | | | | | | | | | | | Determining things like precision and scale in postgresql will require the given blocks to take additional arguments besides the OID. - Adds the ability to handle additional arguments to `TypeMap` - Passes the column type to blocks when looking up PG types | ||||
* | | pg, re-introduce `PostgreSQL::Utils` to unify schema/table extraction. | Yves Senn | 2014-05-19 | 1 | -18/+1 |
| | | | | | | | | Partial revert of c0bfc3f412834ffe8327a15ae3a46602cc28e425 | ||||
* | | :scissors: | Rafael Mendonça França | 2014-05-14 | 1 | -1/+0 |
| | | |||||
* | | PostgreSQLAdapter::Utils seems to be only used from a single spot - quite ↵ | kares | 2014-05-14 | 1 | -1/+19 |
| | | | | | | | | redundant | ||||
* | | PostgreSQL's SchemaStatements seems a could candidate for re-use (with AR-JDBC) | kares | 2014-05-14 | 1 | -6/+2 |
| | | |||||
* | | pg, `change_column_default` accepts `[]`. Closes #11586. | Yves Senn | 2014-05-12 | 1 | -0/+1 |
| | | |||||
* | | Handle other pk types in PostgreSQL gracefully. | Patrick Robertson | 2014-05-12 | 1 | -1/+1 |
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | In #10410 it was noted that you can no longer create PK's with the type of bigserial in PostgreSQL in 4.0.0.rc1. This is mostly because the newer adapter is checking for column type with the id column instead of just letting it pass through like it did before. Side effects: You may just create a PK column of a type that you really don't want to be your PK. As far as I can tell this was allowed in 3.2.X and perhaps an exception should be raised if you try and do something extremely dumb. | ||||
* | | refactor, move `column_for` to `AbstractAdapter` for better reuse. | Yves Senn | 2014-05-04 | 1 | -4/+0 |
| | | |||||
* | | Changed change_column in PG schema_statements.rb to make sure that the ↵ | Eric Chahin | 2014-04-15 | 1 | -2/+8 |
| | | | | | | | | uuid_generate function was not being quoted. | ||||
* | | PostgreSQL, adapter automatically reloads it's type map. Closes #14678. | Yves Senn | 2014-04-11 | 1 | -3/+1 |
| | | | | | | | | [Yves Senn & Matthew Draper] | ||||
* | | PostgreSQL, Support for materialized views. [Dave Lee & Yves Senn] | Dave Lee | 2014-04-02 | 1 | -4/+1 |
| | | | | | | | | | | Expand the query used in #table_exists? to include materialized views in the kinds of relations it searches. | ||||
* | | Postgres schema: Constrain sequence search classid | Josh Williams | 2014-03-20 | 1 | -0/+1 |
| | | | | | | | | | | | | | | | | | | | | | | The pk_an_sequence_for query previously joined against pg_class's oid for rows in pg_depend, but pg_depend's objid may point to other system tables, such as pg_attrdef. If a row in one of those other tables coincidentally has the same oid as an (unrelated) sequence, that sequence name may be returned instead of the real one. This ensures that only the pg_depend entries pointing to pg_class are considered. | ||||
* | | psql implementation of #index_name_exists? | Jonathan Baudanza | 2014-01-16 | 1 | -0/+13 |
| | | |||||
* | | make the type_map per connection. fixes #13182 | Aaron Patterson | 2013-12-04 | 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 |
| | | |||||
* | | `change_column` for PG adapter respects `:array` option. | Yves Senn | 2013-07-16 | 1 | -2/+3 |
|/ | |||||
* | Reject blank order_values within #columns_for_distinct, as the orders aren't ↵ | Ben Woosley | 2013-05-10 | 1 | -1/+1 |
| | | | | used at all on non-postgres adapters. | ||||
* | Fix that #exists? can produce invalid SQL: "SELECT DISTINCT DISTINCT" | Ben Woosley | 2013-05-10 | 1 | -7/+2 |
| | | | | | | | | | | | | The combination of a :uniq => true association and the #distinct call in #construct_limited_ids_condition combine to create invalid SQL, because we're explicitly selecting DISTINCT, and also sending #distinct on to AREL, via the relation#distinct_value. Rather than build a select distinct clause in #construct_limited_ids_condition, I set #distinct! and pass just the columns into the select statement. This requires introducing a #columns_for_distinct method to return the select columns but not the statement itself. | ||||
* | Make SchemaDumper emit "id: :uuid" when appropriate. Fixes #10451. | Brian Buchanan | 2013-05-03 | 1 | -1/+2 |
| | |||||
* | Do not calculate values if they are not going to be used | Carlos Antonio da Silva | 2013-03-30 | 1 | -7/+9 |
| | | | | | | | | | When building the indexes list in PostgreSQL, IndexDefinition objects are only created if the query for the related attributes really returns something matching the attributes. In case it does not, the variables for building the definition objects were being created but not used. | ||||
* | Add support for FULLTEXT and SPATIAL indexes using the :type flag for MySQL. | Ken Mazaika | 2013-03-27 | 1 | -2/+2 |
| | |||||
* | Adds support for concurrent indexing in PostgreSQL adapter | Dan McClain | 2013-03-25 | 1 | -6/+2 |
| | | | | | | | | Adds support for algorithm option in MySQL indexes Moves USING and algorithm options upstream The syntax is still specific to the Adapter, so the actual executed string happens in the corresponding adapter | ||||
* | Custom index type support with :using. | doabit | 2013-03-24 | 1 | -1/+11 |
| | |||||
* | add uuid primary key support | Aaron Patterson | 2013-03-22 | 1 | -0/+9 |
| | |||||
* | push the mysql add_column up to the abstract adapter | Aaron Patterson | 2013-03-22 | 1 | -10/+4 |
| | |||||
* | allow multiple add columns | Aaron Patterson | 2013-03-22 | 1 | -1/+1 |
| | |||||
* | pull add_column_options! off the pg connection class | Aaron Patterson | 2013-03-22 | 1 | -0/+13 |
| | |||||
* | add a pg visitor for dealing with schema modification | Aaron Patterson | 2013-03-22 | 1 | -4/+21 |
| | |||||
* | also rename indexes when a table or column is renamed | Yves Senn | 2013-02-20 | 1 | -3/+6 |
| | | | | When a table or a column is renamed related indexes kept their name. This will lead to confusing names. This patch renames related indexes when a column or a table is renamed. Only indexes with names generated by rails will be renamed. Indexes with custom names will not be renamed. | ||||
* | Add postgresql range types support | bUg | 2013-01-23 | 1 | -8/+0 |
| |