title: how to explode Nested data frame in PySpark and further store it to hive
body: <p>I am facing a certain issue in which i have my JSON structure as follows :-</p>
  
  <pre><code>{A:value,
  B:value,
  C:Array&lt;Struct&lt;A1:value,B1:value, C1:Array&lt;struct&lt;A2:value,B2:value&gt;&gt;&gt;&gt;
  }
  </code></pre>
  
  <p>i would want it to be exploded in the following form:-</p>
  
  <pre><code>{
  A:value,
  B:value,
  A1:value,
  B1:value,
  A2:value,
  B2:value
  }
  </code></pre>
  
  <p>I am using pyspark dataframes for this and couldn't find a way to explode properly. any help is appreciated. </p>