Forum Discussion
Anonymous
1 year agoNot applicable
Issues executing notebook using custom databricks library uploaded
I have been trying to process xml content using pyspark and dataframes as per the solution in the post https://community.fabric.microsoft.com/t5/Data-Engineering/Spark-XML-does-not-work-with-pyspark/...
- Anonymous1 year ago
Hi Anonymous
A simple workaround is to use Pandas to read data from the xml file into a Pandas dataframe, then convert the Pandas dataframe into a Spark dataframe. For example,
Best Regards,
Jing
If this post helps, please Accept it as Solution to help other members find it. Appreciate your Kudos!
Anonymous
1 year agoNot applicable
Hi Anonymous
A simple workaround is to use Pandas to read data from the xml file into a Pandas dataframe, then convert the Pandas dataframe into a Spark dataframe. For example,
Best Regards,
Jing
If this post helps, please Accept it as Solution to help other members find it. Appreciate your Kudos!
Anonymous
1 year agoNot applicable
Perfect, works perfectly in my test case... now to try it in my real world scenarios