PySpark - Column

Card Puncher Data Processing

PySpark - Column

About

Spark DataSet - Column in PySpark

Import

The col function in Python is dynamic. You cannot then import the name, you need to import the whole function:

from pyspark.sql.functions import *

then you can suppress the inspection

# noinspection PyUnresolvedReferences
maxAge = words \
    .agg(max(col("age")).alias("age")) \
    .collect()

Documentation / Reference







Share this page:
Follow us:
Task Runner