Ctrl+K
Logo image Logo image

Site Navigation

  • API Reference
  • Examples

Site Navigation

  • API Reference
  • Examples

Section Navigation

  • PyFlink Table
  • PyFlink DataFrame
    • DataFrame
    • DataFrame Creation
    • Input/Output
    • SQL
    • Data Types
    • User Defined Functions
    • Configuration
    • Catalog
    • GPU Support
    • AI / LLM
  • PyFlink Multimodal
  • PyFlink DataStream
  • PyFlink Common

pyflink.dataframe.DataFrame.join_lateral#

DataFrame.join_lateral(table_function_call: Union[pyflink.table.expression.Expression, DataFrameUDTFCall], *, on: Optional[pyflink.table.expression.Expression[bool]] = None, ignore_empty: bool = True) → DataFrame[source]#

Join with an element-wise UDTF call.

ignore_empty=True uses inner lateral join semantics. ignore_empty=False preserves input rows whose UDTF emits no rows.

DataFrame UDTF calls use output names from alias when present; otherwise they use named TypedDict or struct return_dtype fields. Raw Expression arguments must define output column names with alias. The DataFrame API validates those output names against existing columns. The on predicate is a boolean expression, matching the Table API lateral join predicate.

Example::
>>> from typing import Iterator
>>> from pyflink.dataframe import col, udtf
>>>
>>> @udtf
... def chars(text: str) -> Iterator[str]:
...     for ch in text:
...         yield ch
>>>
>>> df.join_lateral(chars(col("text")).alias("ch"))
>>> df.join_lateral(
...     chars(col("text")).alias("ch"),
...     on=col("id") > 0,
... )
>>> df.join_lateral(
...     chars(col("text")).alias("ch"),
...     ignore_empty=False,
... )

previous

pyflink.dataframe.DataFrame.join_asof

next

pyflink.dataframe.DataFrame.union

Show Source

Created using Sphinx 4.5.0.