Forum Discussion
Python script: Error tokenizing data
- 7 years ago
Hard to say without more info on the error.
I would try, Highlight all columns, go to Transform > Format > Clean. Then doTransform > Format > Trim.
If this does not work still, try renaming each of the column headers, maybe just test with A / B / C etc to see if that works.
If still erroring, it may be useful to see the M code, if you copy the code from Home > Advanced Editor.
Love hearing about Power BI tips, jobs and news?
I love to share about these - connect with me!Stay up to date on
Read my blogs onRemember to spread knowledge in the community when you can!
Hard to say without more info on the error.
I would try, Highlight all columns, go to Transform > Format > Clean. Then doTransform > Format > Trim.
If this does not work still, try renaming each of the column headers, maybe just test with A / B / C etc to see if that works.
If still erroring, it may be useful to see the M code, if you copy the code from Home > Advanced Editor.
Love hearing about Power BI tips, jobs and news?
I love to share about these - connect with me!
Stay up to date on
Read my blogs on
Remember to spread knowledge in the community when you can!
- dbarrera7 years agoFrequent Visitor
Thanks for all your help!
I don't understand why but I did all your recommendations together and it worked:
1st. Clean and trim example file before combination as you explained
2nd. Replace (,) for blank in example file before combination
3rd. Clean and trim combined table
4th. Change column name for A / B / C...
5th. Execute Python Script
Thank you very much!
- SteveCampbell7 years agoMemorable Member
There was something in there causing an issue. Pandas often has problems with characters - may have been an invisible character, or something odd.
Quite possible it may have had more than one issue, why only works when they all are used!
Glad it's working!!
Love hearing about Power BI tips, jobs and news?
I love to share about these - connect with me!Stay up to date on
Read my blogs onRemember to spread knowledge in the community when you can!