diff options
Diffstat (limited to 'lib/sqlalchemy/dialects/postgresql')
| -rw-r--r-- | lib/sqlalchemy/dialects/postgresql/base.py | 17 | ||||
| -rw-r--r-- | lib/sqlalchemy/dialects/postgresql/psycopg2.py | 5 |
2 files changed, 14 insertions, 8 deletions
diff --git a/lib/sqlalchemy/dialects/postgresql/base.py b/lib/sqlalchemy/dialects/postgresql/base.py index 85665dc41..29f1651fb 100644 --- a/lib/sqlalchemy/dialects/postgresql/base.py +++ b/lib/sqlalchemy/dialects/postgresql/base.py @@ -82,9 +82,10 @@ to inspect the actual value using:: SHOW search_path; -Prior to version 0.7.3, cross-schema foreign keys when the schemas -were also in the ``search_path`` could make an incorrect assumption -if the schemas were explicitly stated on each :class:`.Table`. +.. versionchanged:: 0.7.3 + Prior to this version, cross-schema foreign keys when the schemas + were also in the ``search_path`` could make an incorrect assumption + if the schemas were explicitly stated on each :class:`.Table`. Background on PG's ``search_path`` is at: http://www.postgresql.org/docs/9.0/static/ddl-schemas.html#DDL-SCHEMAS-PATH @@ -137,7 +138,7 @@ Operator Classes PostgreSQL allows the specification of an *operator class* for each column of an index (see http://www.postgresql.org/docs/8.3/interactive/indexes-opclass.html). The :class:`.Index` construct allows these to be specified via the ``postgresql_ops`` -keyword argument (new as of SQLAlchemy 0.7.2):: +keyword argument:: Index('my_index', my_table.c.id, my_table.c.data, postgresql_ops={ @@ -145,6 +146,9 @@ keyword argument (new as of SQLAlchemy 0.7.2):: 'id': 'int4_ops' }) +.. versionadded:: 0.7.2 + ``postgresql_ops`` keyword argument to :class:`.Index` construct. + Note that the keys in the ``postgresql_ops`` dictionary are the "key" name of the :class:`.Column`, i.e. the name used to access it from the ``.c`` collection of :class:`.Table`, which can be configured to be different than the actual @@ -467,8 +471,9 @@ class ENUM(sqltypes.Enum): the :meth:`~.postgresql.ENUM.create` and :meth:`~.postgresql.ENUM.drop` methods can be used to emit SQL to a target bind. - (new in 0.7.4) - + + .. versionadded:: 0.7.4 + """ self.create_type = kw.pop("create_type", True) super(ENUM, self).__init__(*enums, **kw) diff --git a/lib/sqlalchemy/dialects/postgresql/psycopg2.py b/lib/sqlalchemy/dialects/postgresql/psycopg2.py index 5aa93978b..ec8d0f219 100644 --- a/lib/sqlalchemy/dialects/postgresql/psycopg2.py +++ b/lib/sqlalchemy/dialects/postgresql/psycopg2.py @@ -96,8 +96,9 @@ on all new connections based on the value passed to engine = create_engine("postgresql://user:pass@host/dbname", client_encoding='utf8') This overrides the encoding specified in the Postgresql client configuration. -The psycopg2-specific ``client_encoding`` parameter to :func:`.create_engine` is new as of -SQLAlchemy 0.7.3. + +.. versionadded:: 0.7.3 + The psycopg2-specific ``client_encoding`` parameter to :func:`.create_engine`. SQLAlchemy can also be instructed to skip the usage of the psycopg2 ``UNICODE`` extension and to instead utilize it's own unicode encode/decode |
