MCPcopy Create free account
hub / github.com/sqlalchemy/sqlalchemy / visit_join

Method visit_join

lib/sqlalchemy/dialects/mysql/base.py:1715–1744  ·  view source on GitHub ↗
(
        self,
        join: selectable.Join,
        asfrom: bool = False,
        from_linter: Optional[compiler.FromLinter] = None,
        **kwargs: Any,
    )

Source from the content-addressed store, hash-verified

1713 return super().get_select_precolumns(select, **kw)
1714
1715 def visit_join(
1716 self,
1717 join: selectable.Join,
1718 asfrom: bool = False,
1719 from_linter: Optional[compiler.FromLinter] = None,
1720 **kwargs: Any,
1721 ) -> str:
1722 if from_linter:
1723 from_linter.edges.add((join.left, join.right))
1724
1725 if join.full:
1726 join_type = " FULL OUTER JOIN "
1727 elif join.isouter:
1728 join_type = " LEFT OUTER JOIN "
1729 else:
1730 join_type = " INNER JOIN "
1731
1732 return "".join(
1733 (
1734 self.process(
1735 join.left, asfrom=True, from_linter=from_linter, **kwargs
1736 ),
1737 join_type,
1738 self.process(
1739 join.right, asfrom=True, from_linter=from_linter, **kwargs
1740 ),
1741 " ON ",
1742 self.process(join.onclause, from_linter=from_linter, **kwargs), # type: ignore[arg-type] # noqa: E501
1743 )
1744 )
1745
1746 def for_update_clause(
1747 self, select: selectable.GenerativeSelect, **kw: Any

Callers

nothing calls this directly

Calls 3

addMethod · 0.45
joinMethod · 0.45
processMethod · 0.45

Tested by

no test coverage detected