I have a dataframe as
Sales PctSales
Id1 12929.63 0.12278547
Id2 90063.39 0.85528156
Id3 2309.60 0.02193298
I want to save this data in SQL Server. I am using RODBC. So, I need to convert it to XML. Which might look like this.
<salesReport>
<employee id="Id1" sales="12929.63" pctSales="0.12278547"/>
<employee id="Id2" sales="90063.39" pctSales="0.85528156"/>
<employee id="Id3" sales="2309.60" pctSales="0.02193298"/>
</salesReport>
First column in input data does not have column name.
No comments:
Post a Comment