def LateralJoin(lhs, rhs, join_type='LEFT', condition=True):
    return Clause(
        lhs,
        SQL('%s JOIN LATERAL' % join_type),
        rhs,
        SQL('ON %s', condition))
dataset/ETHPy150Open coleifer/peewee/playhouse/postgres_ext.py/LateralJoin/original