Mike Bayer [Tue, 12 Jun 2012 00:11:05 +0000 (20:11 -0400)]
- [bug] Fixed bug affecting Py3K whereby
string positional parameters passed to
engine/connection execute() would fail to be
interpreted correctly, due to __iter__
being present on Py3K string.
[ticket:2503]. Also in 0.7.8.
Mike Bayer [Fri, 8 Jun 2012 19:56:58 +0000 (15:56 -0400)]
Add some `Sphinx` related version informations paragraph-level markups,
such as ``.. versionaddedd::``, ``.. versionchanged::`` and ``.. deprecated::``.
Mike Bayer [Fri, 1 Jun 2012 20:22:44 +0000 (16:22 -0400)]
- [bug] Fixed memory leak in C version of
result proxy whereby DBAPIs which don't deliver
pure Python tuples for result rows would
fail to decrement refcounts correctly.
The most prominently affected DBAPI
is pyodbc. [ticket:2489]
Mike Bayer [Thu, 24 May 2012 22:49:23 +0000 (18:49 -0400)]
- [bug] Dialect no longer emits expensive server
collations query, as well as server casing,
on first connect. These functions are still
available as semi-private. [ticket:2404]
Mike Bayer [Thu, 24 May 2012 14:58:43 +0000 (10:58 -0400)]
- identify another condition, indirectly via #2491, where
remote/local detection was regressing vs. 0.7. use a more
liberal check for "tables overlap".
Mike Bayer [Thu, 24 May 2012 14:17:54 +0000 (10:17 -0400)]
- [bug] Fixed bug in declarative
whereby the precedence of columns
in a joined-table, composite
column (typically for id) would fail to
be correct if the columns contained
names distinct from their attribute
names. This would cause things like
primaryjoin conditions made against the
entity attributes to be incorrect. Related
to [ticket:1892] as this was supposed
to be part of that, this is [ticket:2491].
Also in 0.7.8.
Mike Bayer [Fri, 18 May 2012 14:55:28 +0000 (10:55 -0400)]
- reorganize the usage of __mapper_args__ so that it's only
called after the __prepare__() step, if any, so that everything to
do with the mapping occurs after the table is reflected.
Mike Bayer [Thu, 17 May 2012 19:48:39 +0000 (15:48 -0400)]
- [feature] Added utility feature
Session.enable_relationship_loading(),
supersedes relationship.load_on_pending.
Both features should be avoided, however.
[ticket:2372]
Mike Bayer [Thu, 17 May 2012 18:18:05 +0000 (14:18 -0400)]
- [bug] Fixed bug whereby subqueryload() from
a polymorphic mapping to a target would incur
a new invocation of the query for each
distinct class encountered in the polymorphic
result. [ticket:2480]. Also in 0.7.8.
Mike Bayer [Thu, 17 May 2012 15:45:05 +0000 (11:45 -0400)]
- [feature] The "deferred declarative
reflection" system has been moved into the
declarative extension itself, using the
new DeferredReflection class. This
class is now tested with both single
and joined table inheritance use cases.
[ticket:2485]
- [bug] The autoload_replace flag on Table,
when False, will cause any reflected foreign key
constraints which refer to already-declared
columns to be skipped, assuming that the
in-Python declared column will take over
the task of specifying in-Python ForeignKey
or ForeignKeyConstraint declarations.
Mike Bayer [Tue, 15 May 2012 15:57:30 +0000 (17:57 +0200)]
implement support for __prepare__ declarative method. this signals that
the mapping should not be constructed immediately; instead, the info for
the mapping is placed into an interm object _MapperThingy which serves
as the mapper for the purposes of figuring out inheritance, etc. Later,
the prepare_deferred_mapping() function can be called given a base which
will invoke __prepare__ for each mapped class.
Mike Bayer [Fri, 4 May 2012 23:27:57 +0000 (19:27 -0400)]
- [bug] Fixed issue in unit of work
whereby setting a non-None self-referential
many-to-one relationship to None
would fail to persist the change if the
former value was not already loaded.
[ticket:2477].
Mike Bayer [Fri, 4 May 2012 22:40:55 +0000 (18:40 -0400)]
- [bug] Quoting information is now passed along
from a Column with quote=True when generating
a same-named bound parameter to the bindparam()
object, as is the case in generated INSERT and UPDATE
statements, so that unknown reserved names can
be fully supported. [ticket:2437]
Mike Bayer [Fri, 4 May 2012 21:44:22 +0000 (17:44 -0400)]
- [feature] Added SQLite execution option
"sqlite_raw_colnames=True", will bypass
attempts to remove "." from column names
returned by SQLite cursor.description.
[ticket:2475]
Mike Bayer [Wed, 25 Apr 2012 14:38:24 +0000 (10:38 -0400)]
- [bug] Fixed bug in relationship comparisons
whereby calling unimplemented methods like
SomeClass.somerelationship.like() would
produce a recursion overflow, instead
of NotImplementedError.
Mike Bayer [Tue, 24 Apr 2012 22:06:27 +0000 (18:06 -0400)]
- [feature] Calling rollback() within a
session.begin_nested() will now only expire
those objects that had net changes within the
scope of that transaction, that is objects which
were dirty or were modified on a flush. This
allows the typical use case for begin_nested(),
that of altering a small subset of objects, to
leave in place the data from the larger enclosing
set of objects that weren't modified in
that sub-transaction. [ticket:2452]
- inline the "register_newly_XYZ" functions to operate
upon collections to reduce method calls
Mike Bayer [Tue, 24 Apr 2012 20:44:53 +0000 (16:44 -0400)]
- [feature] postgresql.ARRAY features an optional
"dimension" argument, will assign a specific
number of dimensions to the array which will
render in DDL as ARRAY[][]..., also improves
performance of bind/result processing.
[ticket:2441]
Mike Bayer [Tue, 24 Apr 2012 20:27:58 +0000 (16:27 -0400)]
- [feature] The "unconsumed column names" warning emitted
when keys are present in insert.values() or update.values()
that aren't in the target table is now an exception.
[ticket:2415]
Mike Bayer [Tue, 24 Apr 2012 20:25:20 +0000 (16:25 -0400)]
- [feature] Inspector.get_primary_keys() is
deprecated; use Inspector.get_pk_constraint().
Courtesy Diana Clarke. [ticket:2422]
- restored default get_primary_keys()/get_pk_constraint() wrapper
to help maintain compatibility with third party dialects
created against 0.6 or 0.7
Mike Bayer [Tue, 24 Apr 2012 20:08:35 +0000 (16:08 -0400)]
- [bug] All of UniqueConstraint, ForeignKeyConstraint,
CheckConstraint, and PrimaryKeyConstraint will
attach themselves to their parent table automatically
when they refer to a Table-bound Column object directly
(i.e. not just string column name), and refer to
one and only one Table. Prior to 0.8 this behavior
occurred for UniqueConstraint and PrimaryKeyConstraint,
but not ForeignKeyConstraint or CheckConstraint.
[ticket:2410]
Mike Bayer [Tue, 24 Apr 2012 20:03:00 +0000 (16:03 -0400)]
- [feature] The behavior of column targeting
in result sets is now case sensitive by
default. SQLAlchemy for many years would
run a case-insensitive conversion on these values,
probably to alleviate early case sensitivity
issues with dialects like Oracle and
Firebird. These issues have been more cleanly
solved in more modern versions so the performance
hit of calling lower() on identifiers is removed.
The case insensitive comparisons can be re-enabled
by setting "case_insensitive=False" on
create_engine(). [ticket:2423]
Mike Bayer [Tue, 24 Apr 2012 19:52:09 +0000 (15:52 -0400)]
- [feature] The after_attach event is now
emitted after the object is established
in Session.new or Session.identity_map
upon Session.add(), Session.merge(),
etc., so that the object is represented
in these collections when the event
is called. [ticket:2464]
Mike Bayer [Tue, 24 Apr 2012 19:49:52 +0000 (15:49 -0400)]
- [feature] the SQLite date and time types
have been overhauled to support a more open
ended format for input and output, using
name based format strings and regexps. A
new argument "microseconds" also provides
the option to omit the "microseconds"
portion of timestamps. Thanks to
Nathan Wright for the work and tests on
this. [ticket:2363]
Mike Bayer [Sun, 1 Apr 2012 23:42:54 +0000 (19:42 -0400)]
- sql
- [bug] Removed warning when Index is created
with no columns; while this might not be what
the user intended, it is a valid use case
as an Index could be a placeholder for just an
index of a certain name.
- mssql
- [feature] Added interim create_engine flag
supports_unicode_binds to PyODBC dialect,
to force whether or not the dialect
passes Python unicode literals to PyODBC
or not.
Mike Bayer [Sat, 31 Mar 2012 17:35:05 +0000 (13:35 -0400)]
- [bug] Fixed bug in expression annotation
mechanics which could lead to incorrect
rendering of SELECT statements with aliases
and joins, particularly when using
column_property(). [ticket:2453]
Mike Bayer [Sat, 31 Mar 2012 16:55:42 +0000 (12:55 -0400)]
- [bug] Fixed bug whereby polymorphic_on
column that's not otherwise mapped on the
class would be incorrectly included
in a merge() operation, raising an error.
[ticket:2449]
Mike Bayer [Wed, 21 Mar 2012 00:12:26 +0000 (20:12 -0400)]
- 0.7.7
- [feature] Added prefix_with() method
to Query, calls upon select().prefix_with()
to allow placement of MySQL SELECT
directives in statements. Courtesy
Diana Clarke [ticket:2443]
Mike Bayer [Wed, 14 Mar 2012 21:34:36 +0000 (14:34 -0700)]
- [bug] Fixed issue whereby attribute-based
column access on a row would raise
AttributeError with non-C version,
NoSuchColumnError with C version. Now
raises AttributeError in both cases.
[ticket:2398]
Mike Bayer [Wed, 14 Mar 2012 21:32:13 +0000 (14:32 -0700)]
- [feature] Added support for MySQL index and
primary key constraint types
(i.e. USING) via new mysql_using parameter
to Index and PrimaryKeyConstraint,
courtesy Diana Clarke. [ticket:2386]
Mike Bayer [Wed, 14 Mar 2012 03:38:30 +0000 (20:38 -0700)]
- [bug] Fixed bug in C extensions whereby
string format would not be applied to a
Numeric value returned as integer; this
affected primarily SQLite which does
not maintain numeric scale settings.
[ticket:2432]
Nathan Wright [Tue, 13 Mar 2012 04:31:12 +0000 (21:31 -0700)]
Improve SQLite DATETIME storage format handling [ticket:2363]
This breaks backwards compatibility with old SQLite DATETIME, DATE,
and TIME storage_format strings. Formatting now occurs with named instead
of positional parameters. The regexp argument can still use positional
arguments, but named groupings are also supported. This means that you can
omit fields and change the order of date fields as desired.
SQLite's DATETIME and TIME also gained a truncate_microseconds argument.
This is shorthand for modifying the format string. Fortunately the
str_to_datetime and str_to_time processors written in C already support
omitting microseconds, so we don't have to resort to python processing
for this case.