Re: Understanding how to quote XML string in order to serialize using Python's ElementTree

2016-01-09 Thread Karim
Yes it changes your quotechar = "'" into quotechar = '"' You should no more get the double quoting of the data string and no more slicing step. Karim On 10/01/2016 00:15, Saran Ahluwalia wrote: Thank you for the feedback on this. I believe that the excel dialect includes just that: class

Re: Understanding how to quote XML string in order to serialize using Python's ElementTree

2016-01-09 Thread Saran Ahluwalia
Thank you for the feedback on this. I believe that the excel dialect includes just that: class excel(Dialect): delimiter = ',' quotechar = '"' doublequote = True skipinitialspace = False lineterminator = '\r\n' quoting = QUOTE_MINIMAL On Sat, Jan 9, 2016 at 5:23 PM, Karim

Re: Understanding how to quote XML string in order to serialize using Python's ElementTree

2016-01-09 Thread Saran Ahluwalia
As mentioned previously, I assigned the variable *data *to the string ''',0001,0070,". When any utility that attempts to parse this string (this is one example of millions found in my actual data source) you receive that error. You would need to comment out the following: data = row['E

Re: Understanding how to quote XML string in order to serialize using Python's ElementTree

2016-01-09 Thread Karim
On 09/01/2016 21:54, kbtyo wrote: My specs: Python 3.4.3 Windows 7 IDE is Jupyter Notebooks What I have referenced: 1) http://stackoverflow.com/questions/1546717/python-escaping-strings-for-use-in-xml 2) http://stackoverflow.com/questions/7802418/how-to-properly-escape-single-and-double-qu

Re: Understanding how to quote XML string in order to serialize using Python's ElementTree

2016-01-09 Thread Karim
On 09/01/2016 21:54, kbtyo wrote: My specs: Python 3.4.3 Windows 7 IDE is Jupyter Notebooks What I have referenced: 1) http://stackoverflow.com/questions/1546717/python-escaping-strings-for-use-in-xml 2) http://stackoverflow.com/questions/7802418/how-to-properly-escape-single-and-double-qu

Understanding how to quote XML string in order to serialize using Python's ElementTree

2016-01-09 Thread kbtyo
My specs: Python 3.4.3 Windows 7 IDE is Jupyter Notebooks What I have referenced: 1) http://stackoverflow.com/questions/1546717/python-escaping-strings-for-use-in-xml 2) http://stackoverflow.com/questions/7802418/how-to-properly-escape-single-and-double-quotes 3)http://stackoverflow.com/quest