From a81bd92d6ebef5053cbb6882b336c50c1134c273 Mon Sep 17 00:00:00 2001 From: Mike Bayer Date: Wed, 27 Sep 2006 07:08:26 +0000 Subject: - specifying joins in the from_obj argument of query.select() will replace the main table of the query, if the table is somewhere within the given from_obj. this makes it possible to produce custom joins and outerjoins in queries without the main table getting added twice. [ticket:315] - added join_to and outerjoin_to transformative methods to SelectResults, to build up join/outerjoin conditions based on property names. also added select_from to explicitly set from_obj parameter. - factored "results" arrays from the mapper test suite and into the "tables" mapper - added "viewonly" param to docs --- doc/build/content/adv_datamapping.txt | 1 + 1 file changed, 1 insertion(+) (limited to 'doc') diff --git a/doc/build/content/adv_datamapping.txt b/doc/build/content/adv_datamapping.txt index f1afd5c6e..8e6cdc5c6 100644 --- a/doc/build/content/adv_datamapping.txt +++ b/doc/build/content/adv_datamapping.txt @@ -255,6 +255,7 @@ Keyword options to the `relation` function include: * order_by - indicates the ordering that should be applied when loading these items. See the section [advdatamapping_orderby](rel:advdatamapping_orderby) for details. * association - When specifying a many to many relationship with an association object, this keyword should reference the mapper or class of the target object of the association. See the example in [datamapping_association](rel:datamapping_association). * post_update - this indicates that the relationship should be handled by a second UPDATE statement after an INSERT, or before a DELETE. using this flag essentially means the relationship will not incur any "dependency" between parent and child item, as the particular foreign key relationship between them is handled by a second statement. use this flag when a particular mapping arrangement will incur two rows that are dependent on each other, such as a table that has a one-to-many relationship to a set of child rows, and also has a column that references a single child row within that list (i.e. both tables contain a foreign key to each other). If a flush() operation returns an error that a "cyclical dependency" was detected, this is a cue that you might want to use post_update. +* viewonly=(True|False) - when set to True, the relation is used only for loading objects within the relationship, and has no effect on the unit-of-work flush process. relations with viewonly can specify any kind of join conditions to provide additional views of related objects onto a parent object. ### Controlling Ordering {@name=orderby} -- cgit v1.2.1