Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
dfRecovered = dfCategory\
.withColumn("category_id", get_json_object(col("category"), "$.category_id"))\
.withColumn("category_code", get_json_object(col("category"), "$.category_code"))
dfRecovered.printSchema()
dfRecovered.show(truncate=False)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment