summaryrefslogtreecommitdiff
path: root/test/dialect/postgresql/test_reflection.py
Commit message (Collapse)AuthorAgeFilesLines
* Fix typopr/183Pete Hollobon2015-06-221-1/+1
|
* - for #3455Mike Bayer2015-06-191-21/+36
| | | | | | | | | - changelog - versionadded + reflink for new pg storage parameters doc - pep8ing - add additional tests to definitely check that the Index object is created all the way with the opts we want fixes #3455
* Merge remote-tracking branch 'origin/pr/179' into pr179Mike Bayer2015-06-191-0/+39
|\
| * Add reflection of PostgreSQL index access methods (USING clause)pr/179Pete Hollobon2015-06-041-0/+19
| |
| * Add reflection of PostgreSQL index storage optionsPete Hollobon2015-06-041-0/+20
| |
* | - Repaired some typing and test issues related to the pypyMike Bayer2015-06-051-1/+1
|/ | | | | | | | | psycopg2cffi dialect, in particular that the current 2.7.0 version does not have native support for the JSONB type. The version detection for psycopg2 features has been tuned into a specific sub-version for psycopg2cffi. Additionally, test coverage has been enabled for the full series of psycopg2 features under psycopg2cffi. fixes #3439
* - Fixed bug where updated PG index reflection as a result ofMike Bayer2015-04-011-0/+1
| | | | | | | :ticket:`3184` would cause index operations to fail on Postgresql versions 8.4 and earlier. The enhancements are now disabled when using an older version of Postgresql. fixes #3343
* - The :meth:`.PGDialect.has_table` method will now query againstMike Bayer2014-12-041-0/+12
| | | | | | | | | | | ``pg_catalog.pg_table_is_visible(c.oid)``, rather than testing for an exact schema match, when the schema name is None; this so that the method will also illustrate that temporary tables are present. Note that this is a behavioral change, as Postgresql allows a non-temporary table to silently overwrite an existing temporary table of the same name, so this changes the behavior of ``checkfirst`` in that unusual scenario. fixes #3264
* - use provide_metadata for new unique constraint / index testsMike Bayer2014-10-041-23/+51
| | | | | | | | | | | | | | - add a test for PG reflection of unique index without any unique constraint - for PG, don't include 'duplicates_constraint' in the entry if the index does not actually mirror a constraint - use a distinct method for unique constraint reflection within table - catch unique constraint not implemented condition; this may be within some dialects and also is expected to be supported by Alembic tests - migration + changelogs for #3184 - add individual doc notes as well to MySQL, Postgreql fixes #3184
* Reflect unique constraints when reflecting a Table objectJohannes Erdfelt2014-09-171-2/+35
| | | | | | | | | | | | | | | Calls to reflect a table did not create any UniqueConstraint objects. The reflection core made no calls to get_unique_constraints and as a result, the sqlite dialect would never reflect any unique constraints. MySQL transparently converts unique constraints into unique indexes, but SQLAlchemy would reflect those as an Index object and as a UniqueConstraint. The reflection core will now deduplicate the unique constraints. PostgreSQL would reflect unique constraints as an Index object and as a UniqueConstraint object. The reflection core will now deduplicate the unique indexes.
* - repair get_foreign_table_names() for PGInsp/dialect levelpr128Mike Bayer2014-09-171-3/+22
| | | | | - repair get_view_names() - changelog + migration note
* - the actual round trip requires password authent set up for the user;Mike Bayer2014-09-171-25/+7
| | | | we don't actually need a round trip test here as we're only testing reflection.
* - break out and fix tests for materialized view and foreign tables. foreign ↵Mike Bayer2014-09-161-72/+86
| | | | tables not working
* Added documentation. Changed my mind - added get_foreign_table_names() only ↵pr/128Rodrigo Menezes2014-09-051-0/+6
| | | | to PGInspect and not in the Dialect. Added tests for PGInspect and removed a bunch of the old test scaffolding.
* Fixing some pep8s and adding get_foreign_tables.Rodrigo Menezes2014-09-031-6/+11
|
* Removed all mentions to postgresql_relkindRodrigo Menezes2014-08-261-22/+11
|
* Merge branch 'master' of https://github.com/rclmenezes/sqlalchemyRodrigo Menezes2014-08-141-0/+66
|\
| * - public method name is get_enums()Mike Bayer2014-08-131-12/+57
| | | | | | | | | | | | | | | | | | | | | | | | | | | | - return a list of dicts like other methods do - don't combine 'schema' with 'name', leave them separate - support '*' argument so that we can retrieve cross-schema if needed - remove "conn" argument - use bound parameters for 'schema' in SQL - order by schema, name, label - adapt _load_enums changes to column reflection - changelog - module docs for get_enums() - add drop of enums to --dropfirst
| * Public inspector method to load enum listpr/126Ilya Pekelny2014-08-081-0/+21
| | | | | | | | | | Provide opportunity to get enums list via an inspector instance public interface.
* | Added support for postgres_relkind.Rodrigo Menezes2014-08-141-1/+101
|/
* - flake8 all of test/dialect/postgresqlMike Bayer2014-07-251-136/+179
| | | | - add __backend__ to most tests so that pg8000 can start coming in
* - Fixed regression caused by release 0.8.5 / 0.9.3's compatibilityMike Bayer2014-03-251-1/+1
| | | | | | | | | enhancements where index reflection on Postgresql versions specific to only the 8.1, 8.2 series again broke, surrounding the ever problematic int2vector type. While int2vector supports array operations as of 8.1, apparently it only supports CAST to a varchar as of 8.3. fix #3000
* - Support has been improved for Postgresql reflection behavior on very oldMike Bayer2014-02-181-3/+5
| | | | | | | | | | | | (pre 8.1) versions of Postgresql, and potentially other PG engines such as Redshift (assuming Redshift reports the version as < 8.1). The query for "indexes" as well as "primary keys" relies upon inspecting a so-called "int2vector" datatype, which refuses to coerce to an array prior to 8.1 causing failures regarding the "ANY()" operator used in the query. Extensive googling has located the very hacky, but recommended-by-PG-core-developer query to use when PG version < 8.1 is in use, so index and primary key constraint reflection now work on these versions.
* - Added :paramref:`.MetaData.reflect.**dialect_kwargs`Mike Bayer2014-02-021-88/+175
| | | | | | | | | | | | | | | | | | to support dialect-level reflection options for all :class:`.Table` objects reflected. - Added a new dialect-level argument ``postgresql_ignore_search_path``; this argument is accepted by both the :class:`.Table` constructor as well as by the :meth:`.MetaData.reflect` method. When in use against Postgresql, a foreign-key referenced table which specifies a remote schema name will retain that schema name even if the name is present in the ``search_path``; the default behavior since 0.7.3 has been that schemas present in ``search_path`` would not be copied to reflected :class:`.ForeignKey` objects. The documentation has been updated to describe in detail the behavior of the ``pg_get_constraintdef()`` function and how the ``postgresql_ignore_search_path`` feature essentially determines if we will honor the schema qualification reported by this function or not. [ticket:2922]
* - move this test to PG test_reflectionMike Bayer2013-10-251-0/+65
| | | | - don't use locals()
* - Removed a 128-character truncation from the reflection of theMike Bayer2013-10-181-0/+11
| | | | | | server default for a column; this code was original from PG system views which truncated the string for readability. [ticket:2844]
* refactor test suites for postgresql, mssql, mysql into packages.Mike Bayer2013-06-281-0/+460