SailajaB
Databricks Partner

Hi,

Thank you for the reply..

We are using below structure to change/cast the array type struct with nested new names

newteststruct= ArrayType(StructType([

StructField(""nestedAttr1" ,StringType()),

StructField("columnField" ,StringType())]))

Input will come from other source in json format and we are reading into databricks as df.

So here we are applying the schema level transformations as per business to get output in target schema.

So while casting we are facing an issue where when we get an empty array through the i/p extract.

Thank you