pyspark.sql.functions.
upper
Converts a string expression to upper case.
New in version 1.5.0.
Changed in version 3.4.0: Supports Spark Connect.
Column
target column to work on.
upper case values.
Examples
>>> df = spark.createDataFrame(["Spark", "PySpark", "Pandas API"], "STRING") >>> df.select(upper("value")).show() +------------+ |upper(value)| +------------+ | SPARK| | PYSPARK| | PANDAS API| +------------+