O'Reilly logo
  • Patrick Ryan thinks this is interesting:

# in Python from pyspark.sql.functions import get_json_object, json_tuple jsonDF.select( get_json_object(col("jsonString"), "$.myJSONKey.myJSONValue[1]") as "column", json_tuple(

From

Cover of Spark: The Definitive Guide

Note

  • change 'as' to .alias()

  • remove the 'col' specification in the two places