Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-07-2022 04:07 AM
Why don't you first make sure the column is present in your df, and then use the CASE?
f.e. df2 = func_udf(df1, col) #add missing col
df2 = df.withColumn( CASE...)