Mike Bayer [Wed, 31 Oct 2007 19:11:22 +0000 (19:11 +0000)]
- split ScalarInstrumentedAttribute into a "scalar" and an "object" version.
The "object" version loads the existing value on set/del, fires events,
and handles trackparent operations; the "scalar" version does not.
- column loaders now use the "scalar" version of InstrumentedAttribute, so that
event handlers etc. don't fire off for regular column attribute operations.
- some adjustments to AttributeHistory to work properly for non-loaded attributes
- deferred column attributes no longer trigger a load operation when the
attribute is assigned to. in those cases, the newly assigned
value will be present in the flushes' UPDATE statement unconditionally.
Ants Aasma [Wed, 31 Oct 2007 16:30:06 +0000 (16:30 +0000)]
- also added proxying of save_or_update to scoped sessions.
- session.update() raises an error when updating an instance that is already in the session with a different identity
- adjusted zoomarks lower limits so I can get a nice clean run
Mike Bayer [Tue, 30 Oct 2007 18:04:00 +0000 (18:04 +0000)]
- fix to "row switch" behavior, i.e. when an INSERT/DELETE is combined into a
single UPDATE; many-to-many relations on the parent object update properly.
[ticket:841]
- it's an error to session.save() an object which is already persistent
[ticket:840]
- changed a bunch of repr(obj) calls in session.py exceptions to use mapperutil.instance_str()
Mike Bayer [Sun, 28 Oct 2007 21:28:53 +0000 (21:28 +0000)]
- fixed INSERT statements w.r.t. primary key columns that have SQL-expression
based default generators on them; SQL expression executes inline as normal
but will not trigger a "postfetch" condition for the column, for those DB's
who provide it via cursor.lastrowid
Mike Bayer [Sun, 28 Oct 2007 01:51:43 +0000 (01:51 +0000)]
- merged path_based_options branch
- behavior of query.options() is now fully based on paths, i.e. an option
such as eagerload_all('x.y.z.y.x') will apply eagerloading to only
those paths, i.e. and not 'x.y.x'; eagerload('children.children') applies
only to exactly two-levels deep, etc. [ticket:777]
- removes old compiler()/schemagenerator()/schemadropper() methods from mysql dialect
Mike Bayer [Sat, 27 Oct 2007 18:45:20 +0000 (18:45 +0000)]
- inlined a couple of context variables
- PG two phase was calling text() without the correct bind param format, previous compiler checkin revealed issue
Mike Bayer [Sat, 27 Oct 2007 17:41:30 +0000 (17:41 +0000)]
- removed regular expression step from most statement compilations.
also fixes [ticket:833]
- inlining on PG with_returning() call
- extra options added for profiling
Mike Bayer [Thu, 25 Oct 2007 16:57:04 +0000 (16:57 +0000)]
- refactored _compile_properties/_compile_property, removed redundant code.
still a little squirrely but much less complex.
- improved behavior of add_property() etc., fixed [ticket:831] involving
synonym/deferred
Mike Bayer [Sun, 21 Oct 2007 16:36:34 +0000 (16:36 +0000)]
- the whole OperationContext/QueryContext/SelectionContext thing greatly scaled back;
all MapperOptions process the Query and that's it, one very simpliied QueryContext object gets passed
around at query.compile() and query.instances() time
- slight optimization to MapperExtension allowing the mapper to check for the presence of an extended method, takes 3000 calls off of masseagerload.py test (only a slight increase in speed though)
- attempting to centralize the notion of a "path" along mappers/properties, need to define what that is better. heading towards [ticket:777]...
Jason Kirtland [Sat, 20 Oct 2007 17:14:46 +0000 (17:14 +0000)]
Excluding older sqlite versions from the new insert tests. Currently conservative- 2.8 definitely fails, 3.3 works. The 3.0 and 3.1 binaries from sqlite.org segfault for me so the version check should be revisited when possible.
Mike Bayer [Wed, 17 Oct 2007 16:49:15 +0000 (16:49 +0000)]
- removed __len__ from "dynamic" collection as it would require issuing
a SQL "count()" operation, thus forcing all list evaluations to issue
redundant SQL [ticket:818]
Mike Bayer [Tue, 16 Oct 2007 16:03:59 +0000 (16:03 +0000)]
- Fixed SQL compiler's awareness of top-level column labels as used
in result-set processing; nested selects which contain the same column
names don't affect the result or conflict with result-column metadata.
- query.get() and related functions (like many-to-one lazyloading)
use compile-time-aliased bind parameter names, to prevent
name conflicts with bind parameters that already exist in the
mapped selectable.
Mike Bayer [Sun, 14 Oct 2007 19:15:09 +0000 (19:15 +0000)]
- PG reflection, upon seeing the default schema name being used explicitly
as the "schema" argument in a Table, will assume that this is the the
user's desired convention, and will explicitly set the "schema" argument
in foreign-key-related reflected tables, thus making them match only
with Table constructors that also use the explicit "schema" argument
(even though its the default schema).
In other words, SA assumes the user is being consistent in this usage.
Mike Bayer [Sun, 14 Oct 2007 16:56:32 +0000 (16:56 +0000)]
- attempted to add a test for #622 / #751, but cant reproduce the failing condition
- fixed major oracle bug introduced by r3561, since colnames come back as unicode now,
need to encode keys in setinputsizes() step
Roger Demetrescu [Fri, 12 Oct 2007 12:53:33 +0000 (12:53 +0000)]
firebird: Fixed reflection for Integer and Numeric (after introducing Float column type). Need to review 'column_func' from reflecttable() and write some unit tests...
Roger Demetrescu [Fri, 12 Oct 2007 06:02:15 +0000 (06:02 +0000)]
Firebird: added Float and Time types (FBFloat and FBTime). Fixed BLOB SUB_TYPE for TEXT and Binary types.
Firebird's string types are tested in testtypes.py