```
SELECT * FROM t0 ASOF LEFT JOIN t1 ON (t1.x = t0.x) AND greater(('\0llall\0ll\0ll\0llall\0llall\0llall\0llall\0llall\0llall\0llall\0llall\0llall\0llall\0ll\0ll\0llall\0llall\0llall', x, x, y), t0.y, t1.y)
```

throw Exception("Column '" + name + "' is ambiguous", ErrorCodes::AMBIGUOUS_COLUMN_NAME);
            }
            if (in_left_table)
                membership = 1;
            if (in_right_table)
                membership = 2;
        }
        if (membership && table_number == 0)
        {
            table_number = membership;
            std::swap(ident, identifiers[0]); 
        }
        if (membership && membership != table_number)
        {
            throw Exception("Invalid columns in JOIN ON section. Columns "
                        + identifiers[0]->getAliasOrColumnName() + " and " + ident->getAliasOrColumnName()
                        + " are from different tables.", ErrorCodes::INVALID_JOIN_ON_EXPRESSION);
        }
    }
    return table_number;
}
[[noreturn]] void CollectJoinOnKeysMatcher::throwSyntaxException(const String & msg)
{
    throw Exception("Invalid expression for JOIN ON. " + msg +
        " Supported syntax: JOIN ON Expr([table.]column, ...) = Expr([table.]column, ...) "
        "[AND Expr([table.]column, ...) = Expr([table.]column, ...) ...]",
        ErrorCodes::INVALID_JOIN_ON_EXPRESSION);
}
}