summaryrefslogtreecommitdiff
path: root/lib/sqlalchemy/dialects/postgresql
Commit message (Collapse)AuthorAgeFilesLines
* Changed pg8000 dialect to cope with native JSONpr/132Tony Locke2015-01-031-1/+12
| | | | | For versions > 1.10.1 pg8000 returns de-serialized JSON objects rather than a string. SQL parameters are still strings though.
* Make pg8000 version detection more robustTony Locke2014-12-161-6/+11
| | | | | | pg8000 uses Versioneer, which means that development versions have version strings that don't fit into the dotted triple number format. Released versions will always fit the triple format though.
* pg8000 client_encoding in create_engine()Tony Locke2014-12-161-7/+54
| | | | | The pg8000 dialect now supports the setting of the PostgreSQL parameter client_encoding from create_engine().
* - The :meth:`.PGDialect.has_table` method will now query againstMike Bayer2014-12-041-1/+2
| | | | | | | | | | | ``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
* - in lieu of adding a new system of translating bound parameter namesMike Bayer2014-11-101-0/+49
| | | | | | | for psycopg2 and others, encourage users to take advantage of positional styles by documenting "paramstyle". A section is added to psycopg2 specifically as this is a pretty common spot for named parameters that may be unusually named. fixes #3246.
* - clean up unicode docs and clarify that client_encodingMike Bayer2014-10-071-13/+53
| | | | | at the engine level is not the same thing as at the connect args level.
* - use provide_metadata for new unique constraint / index testsMike Bayer2014-10-041-12/+40
| | | | | | | | | | | | | | - 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
* Merge branch 'reflect-unique-constraints' of ↵Mike Bayer2014-10-041-5/+13
|\ | | | | | | https://bitbucket.org/jerdfelt/sqlalchemy into pr30
| * Reflect unique constraints when reflecting a Table objectJohannes Erdfelt2014-09-171-5/+13
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 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.
* | - A revisit to this issue first patched in 0.9.5, apparentlyMike Bayer2014-09-291-5/+9
|/ | | | | | | | | | psycopg2's ``.closed`` accessor is not as reliable as we assumed, so we have added an explicit check for the exception messages "SSL SYSCALL error: Bad file descriptor" and "SSL SYSCALL error: EOF detected" when detecting an is-disconnect scenario. We will continue to consult psycopg2's connection.closed as a first check. fixes #3021
* - repair get_foreign_table_names() for PGInsp/dialect levelpr128Mike Bayer2014-09-171-16/+31
| | | | | - repair get_view_names() - changelog + migration note
* Merge remote-tracking branch 'origin/pr/128' into pr128Mike Bayer2014-09-161-3/+20
|\
| * Added documentation. Changed my mind - added get_foreign_table_names() only ↵pr/128Rodrigo Menezes2014-09-051-19/+17
| | | | | | | | to PGInspect and not in the Dialect. Added tests for PGInspect and removed a bunch of the old test scaffolding.
| * Added get_foreign_table_names to interface and put it in the test requirements.Rodrigo Menezes2014-09-051-0/+1
| |
| * Fixing some pep8s and adding get_foreign_tables.Rodrigo Menezes2014-09-031-2/+20
| |
| * Removed changes that are no longer necessary for postgresql_relkind. Also, ↵Rodrigo Menezes2014-08-261-2/+2
| | | | | | | | removed newline changes.
| * Merge branch 'master' of https://github.com/zzzeek/sqlalchemy into ↵Rodrigo Menezes2014-08-262-4/+82
| |\ | | | | | | | | | feature/postgres-relkind
| * | Remove relkind from construct arguments.Rodrigo Menezes2014-08-261-2/+1
| | |
| * | Removed all mentions to postgresql_relkindRodrigo Menezes2014-08-261-29/+9
| | |
| * | Add a view synonym too for consistency.Rodrigo Menezes2014-08-141-1/+2
| | |
| * | Merge branch 'master' of https://github.com/rclmenezes/sqlalchemyRodrigo Menezes2014-08-142-23/+73
| |\ \
| * | | Added support for postgres_relkind.Rodrigo Menezes2014-08-141-12/+32
| | | |
* | | | - ensure literal_binds works with LIMIT clause, FOR UPDATEMike Bayer2014-09-031-5/+5
| | | |
* | | | - updates to migration / changelog for 1.0Mike Bayer2014-08-261-1/+1
| |_|/ |/| |
* | | - pep8 formatting for pg table opts feature, testsMike Bayer2014-08-231-24/+59
| | | | | | | | | | | | | | | | | | | | | - add support for PG INHERITS - fix mis-named tests - changelog fixes #2051
* | | Adding postgres create table options documentationpr/129Malik Diarra2014-08-171-0/+16
| | |
* | | Correcting options name from withoids to with_oidsMalik Diarra2014-08-171-3/+3
| | |
* | | quoting tablespace name in create table command in postgresql dialectMalik Diarra2014-08-171-1/+2
| | |
* | | Adding oids and on_commit table optionsMalik Diarra2014-08-171-1/+11
| | |
* | | Adding a tablespace options for postgresql create tableMalik Diarra2014-08-171-1/+9
| | |
* | | - changelog for pullreq github:125Mike Bayer2014-08-161-0/+10
| | | | | | | | | | | | - add pg8000 version detection for the "sane multi rowcount" feature
* | | Merge remote-tracking branch 'origin/pr/125' into pr125Mike Bayer2014-08-161-3/+1
|\ \ \ | |_|/ |/| |
| * | pg8000 now supports sane_multi_rowcountpr/125Tony Locke2014-08-021-1/+1
| | | | | | | | | | | | | | | From pg8000-1.9.14 sane_multi_rowcount is supported so this commit updates the dialect accordingly.
| * | Remove spurious print statements in pg8000 dialectTony Locke2014-08-021-2/+0
| | |
* | | - public method name is get_enums()Mike Bayer2014-08-131-26/+67
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - 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-2/+10
| | | | | | | | | | | | | | | Provide opportunity to get enums list via an inspector instance public interface.
* | | DropEnumType class available from postgres dialectIlya Pekelny2014-08-081-2/+3
| |/ |/|
* | -Fixed bug where Postgresql JSON type was not able to persist orMike Bayer2014-08-071-0/+29
|/ | | | | | | | | | | | | | | | | otherwise render a SQL NULL column value, rather than a JSON-encoded ``'null'``. To support this case, changes are as follows: * The value :func:`.null` can now be specified, which will always result in a NULL value resulting in the statement. * A new parameter :paramref:`.JSON.none_as_null` is added, which when True indicates that the Python ``None`` value should be peristed as SQL NULL, rather than JSON-encoded ``'null'``. Retrival of NULL as None is also repaired for DBAPIs other than psycopg2, namely pg8000. fixes #3159
* Merge remote-tracking branch 'origin/pr/117' into pg8000Mike Bayer2014-07-251-0/+19
|\
| * Fix support for two phase commit in pg8000 dialectTony Locke2014-07-191-0/+19
| | | | | | | | | | | | | | The postgresql base dialect has problems with two-phase commit because there isn't a standard way of handling autocommit in DBAPI. This commit modifies the pg8000 dialect to use the DBAPI tpc extension, which is supported by pg8000 as of version 1.9.11.
* | Fix argument to array() in array._bind_param()pr/124Andrew2014-07-241-1/+1
| | | | | | array.__init__() expects a list as its sole parameter but inside _bind_param(), instead of sending a list it's sending each item in the list as a separate argument which is incorrect.
* | - Fixed bug introduced in 0.9.5 by new pg8000 isolation level featureMike Bayer2014-07-211-2/+6
| | | | | | | | | | where engine-level isolation level parameter would raise an error on connect. fixes #3134
* | - apply pep8 formatting to sqlalchemy/sql, sqlalchemy/util, sqlalchemy/dialects,Brian Jarrett2014-07-208-350/+434
|/ | | | sqlalchemy/orm, sqlalchemy/event, sqlalchemy/testing
* - Fixed bug in :class:`.Enum` and other :class:`.SchemaType`Mike Bayer2014-07-131-2/+1
| | | | | | | subclasses where direct association of the type with a :class:`.MetaData` would lead to a hang when events (like create events) were emitted on the :class:`.MetaData`. fixes #3124
* - break up the <authors> copyright comment as part of a passMike Bayer2014-07-099-9/+18
| | | | to get all flake8 passing
* - add postgresql_regconfig argument to PG dialect for match() operator,jonathan vanasco2014-07-081-5/+57
| | | | implements PG's to_tsquery('regconfig', 'arg') pattern. fixes #3078
* Merge pull request #101 from ddimmich/mastermike bayer2014-07-073-3/+126
|\ | | | | Postgres 9.4 Jsonb support
| * jsonb support for <@, ?| and ?& added.pr/101Damian Dimmich2014-07-011-1/+18
| | | | | | | | need to see if equality already works.
| * minor cleanup of the jsonb - had extraneous operators that where copiedDamian Dimmich2014-06-281-5/+1
| | | | | | | | | | | | from hstore that don't apply. Add tests for ? and @> operators.
| * add has_key & contains operators for jsonb (ported over from hstore)Damian Dimmich2014-06-281-21/+17
| |