class JoinCondition(object):
Undocumented
Method | __init__ |
Undocumented |
Method | _annotate_fks |
Annotate the primaryjoin and secondaryjoin structures with 'foreign' annotations marking columns considered as foreign. |
Method | _annotate_from_fk_list |
Undocumented |
Method | _annotate_local |
Annotate the primaryjoin and secondaryjoin structures with 'local' annotations. |
Method | _annotate_parentmapper |
Undocumented |
Method | _annotate_present_fks |
Undocumented |
Method | _annotate_remote |
Annotate the primaryjoin and secondaryjoin structures with 'remote' annotations marking columns considered as part of the 'remote' side. |
Method | _annotate_remote_distinct_selectables |
annotate 'remote' in primaryjoin, secondaryjoin when the parent/child tables are entirely separate. |
Method | _annotate_remote_from_args |
annotate 'remote' in primaryjoin, secondaryjoin when the 'remote_side' or '_local_remote_pairs' arguments are used. |
Method | _annotate_remote_secondary |
annotate 'remote' in primaryjoin, secondaryjoin when 'secondary' is present. |
Method | _annotate_remote_with_overlap |
No summary |
Method | _annotate_selfref |
annotate 'remote' in primaryjoin, secondaryjoin when the relationship is detected as self-referential. |
Method | _check_foreign_cols |
Check the foreign key columns collected and emit error messages. |
Method | _check_remote_side |
Undocumented |
Method | _deannotate_pairs |
No summary |
Method | _determine_direction |
Determine if this relationship is one to many, many to one, many to many. |
Method | _determine_joins |
Determine the 'primaryjoin' and 'secondaryjoin' attributes, if not passed to the constructor already. |
Method | _gather_columns_with_annotation |
Undocumented |
Method | _gather_join_annotations |
Undocumented |
Method | _has_annotation |
Undocumented |
Method | _log_joins |
Undocumented |
Method | _refers_to_parent_table |
Return True if the join condition contains column comparisons where both columns are in both tables. |
Method | _sanitize_joins |
remove the parententity annotation from our join conditions which can leak in here based on some declarative patterns and maybe others. |
Method | _setup_pairs |
Undocumented |
Method | _tables_overlap |
Return True if parent/child tables have some overlap. |
Method | _warn_for_conflicting_sync_targets |
Undocumented |
Method | _warn_non_column_elements |
Undocumented |
Method | create_lazy_clause |
Undocumented |
Method | join_targets |
Given a source and destination selectable, create a join between them. |
Class Variable | _track_overlapping_sync_targets |
Undocumented |
Instance Variable | _local_remote_pairs |
Undocumented |
Instance Variable | _remote_side |
Undocumented |
Instance Variable | can_be_synced_fn |
Undocumented |
Instance Variable | child_equivalents |
Undocumented |
Instance Variable | child_local_selectable |
Undocumented |
Instance Variable | child_persist_selectable |
Undocumented |
Instance Variable | consider_as_foreign_keys |
Undocumented |
Instance Variable | direction |
Undocumented |
Instance Variable | local_remote_pairs |
Undocumented |
Instance Variable | parent_equivalents |
Undocumented |
Instance Variable | parent_local_selectable |
Undocumented |
Instance Variable | parent_persist_selectable |
Undocumented |
Instance Variable | primaryjoin |
Undocumented |
Instance Variable | prop |
Undocumented |
Instance Variable | secondary |
Undocumented |
Instance Variable | secondary_synchronize_pairs |
Undocumented |
Instance Variable | secondaryjoin |
Undocumented |
Instance Variable | self_referential |
Undocumented |
Instance Variable | support_sync |
Undocumented |
Instance Variable | synchronize_pairs |
Undocumented |
Property | _has_foreign_annotations |
Undocumented |
Property | _has_remote_annotations |
Undocumented |
Property | foreign_key_columns |
Undocumented |
Property | local_columns |
Undocumented |
Property | primaryjoin_minus_local |
Undocumented |
Property | primaryjoin_reverse_remote |
Return the primaryjoin condition suitable for the "reverse" direction. |
Property | remote_columns |
Undocumented |
Property | secondaryjoin_minus_local |
Undocumented |
Undocumented
Annotate the primaryjoin and secondaryjoin structures with 'local' annotations.
This annotates all column elements found simultaneously in the parent table and the join condition that don't have a 'remote' annotation set up from _annotate_remote() or user-defined.
Determine the 'primaryjoin' and 'secondaryjoin' attributes, if not passed to the constructor already.
This is based on analysis of the foreign key relationships between the parent and target mapped selectables.
remove the parententity annotation from our join conditions which can leak in here based on some declarative patterns and maybe others.
We'd want to remove "parentmapper" also, but apparently there's an exotic use case in _join_fixture_inh_selfref_w_entity that relies upon it being present, see :ticket:`3364`.
Given a source and destination selectable, create a join between them.
This takes into account aliasing the join clause to reference the appropriate corresponding columns in the target objects, as well as the extra child criterion, equivalent column sets, etc.