Mike Bayer [Thu, 22 Jun 2006 20:03:09 +0000 (20:03 +0000)]
identified another TLTransaction scenario, and adjusted TLConnection/TLSession to fix this as well (reverted previous change, and overriding in_transaction() instead)
Mike Bayer [Thu, 22 Jun 2006 19:46:44 +0000 (19:46 +0000)]
TLConnection insures that it is used to create a transaction via the session when begin() is called, so that it has proper transactional context, + unittests
Mike Bayer [Mon, 19 Jun 2006 20:41:42 +0000 (20:41 +0000)]
when Query does the "nested select" thing, it copies the ORDER BY to be placed on the "outer" select, so that eager loaders modify only the outer one and not the inner one
Robert Leftwich [Sun, 18 Jun 2006 22:16:36 +0000 (22:16 +0000)]
Added some additional data to exception raised in PropertyLoader,_get_direction when cannot determine the direction to specify exactly which relation failed.
Mike Bayer [Sun, 18 Jun 2006 00:56:25 +0000 (00:56 +0000)]
lazy load and deferred load operations require the parent object
to be in a Session to do the operation; whereas before the operation
would just return a blank list or None, it now raises an exception.
Session.update() is slightly more lenient if the session to which
the given object was formerly attached to was garbage collected;
otherwise still requires you explicitly remove the instance from
the previous Session.
Mike Bayer [Sat, 17 Jun 2006 00:53:33 +0000 (00:53 +0000)]
cast converted into its own ClauseElement so that it can have an explicit compilation
function in ANSICompiler
MySQLCompiler then skips most CAST calls since it only seems to support the standard syntax for Date
types; other types now a TODO for MySQL
then, polymorphic_union() function now CASTs null()s to the type corresponding to the columns in the UNION,
since postgres doesnt like mixing NULL with integer types
(long road for that .....)
Mike Bayer [Fri, 16 Jun 2006 19:21:57 +0000 (19:21 +0000)]
more intelligent "removal" of list items when a list attribute is replaced, doesnt actually "remove" the items from teh replaced list just marks them as "removed" from the parent object for history purposes
Mike Bayer [Fri, 16 Jun 2006 19:02:10 +0000 (19:02 +0000)]
removed historyarray test
ForeignKey is more intelligent about locating the parent table it represents, in the case that
its attached to a CompoundSelect column which has multiple "originals", some of which might not be schema.Columns
Mike Bayer [Fri, 16 Jun 2006 03:19:53 +0000 (03:19 +0000)]
fixed bug where if a many-to-many table mapped as "secondary" had other cols in it, delete operations would try to match up on those columns. also fixed bug in new attributes if you set a list based attribute to a blank list, properly fires the 'delete' event for the elements of the previous list
Mike Bayer [Thu, 15 Jun 2006 15:27:39 +0000 (15:27 +0000)]
if an item attached to a parent is found to be already in the session, then the "save-update" cascade operation doesnt take place. currently this prevents unncessessary cascading due to backref events, which was a massive speed hit.
Mike Bayer [Thu, 8 Jun 2006 16:58:14 +0000 (16:58 +0000)]
late compilation of mappers. now you can create mappers in any order, and they will compile their internal state when first used in a query or flush operation (or their props or 'c'/'columns' attributes are used). includes various cleanups and fixes in support of the change, including some unit test changes, additional unit tests.
Jonathan LaCour [Tue, 6 Jun 2006 17:58:41 +0000 (17:58 +0000)]
Further improved the process_relationships function to handle the ordering of
class definitions better. The function was only looking at relationships, not
foreign keys, and was making some improper assumptions. The unit tests all
still pass, and now some of my own code actually works, regardless of the order
that I define the classes in.' 'lib/sqlalchemy/ext/activemapper.py
Mike Bayer [Mon, 5 Jun 2006 22:45:10 +0000 (22:45 +0000)]
"foreignkey" property of PropertyLoader is a sets.Set. removed "foreigntable".
simplified/fixed foreign key location in _find_dependent(), fixes [ticket:151]
Mike Bayer [Wed, 31 May 2006 06:22:06 +0000 (06:22 +0000)]
simplification/improvement to circular dependency sort (properly batches now)
mapper accepts add_property calls with columns that are not in its selectable (allows deferreds in, generally more lenient)
Mike Bayer [Tue, 30 May 2006 17:11:14 +0000 (17:11 +0000)]
further refinement of the polymorphic UOWTask idea. circular dependency sort has to be pretty much focused on the base mappers
of any inheritance chain, as it now takes part in pretty much any two dependent classes who share the same inherited parent.