Skip to main content
Question

XML Parser Error - Invalid Byte


Forum|alt.badge.img

I need a work around for this error. I am using XML reader to extract XLE files to CSV. Anyone have any suggestions? It's weird because some XLE files work, while others dont, all depending on how the file was originaly downloaded. PLEASE SEE COMMENT THREAD How to format CSV Output for more information on my issue.

4 replies

daveatsafe
Safer
Forum|alt.badge.img+19
  • Safer
  • June 6, 2019

Hi @lucasghd,

This error is usually caused by the XML header stating the incorrect encoding for the file. If the file is set to utf-8, try changing to your local system encoding, or vice-versa, using a text editor.


Forum|alt.badge.img
  • Author
  • June 6, 2019
daveatsafe wrote:

Hi @lucasghd,

This error is usually caused by the XML header stating the incorrect encoding for the file. If the file is set to utf-8, try changing to your local system encoding, or vice-versa, using a text editor.

Someone else recommended this, but i wasnt able to get it working. Perhaps i'm not doing something correctly afterwards? Would i not then just add a CSV writter after this?


nielsgerrits
VIP
Forum|alt.badge.img+54
lucasghd wrote:

Someone else recommended this, but i wasnt able to get it working. Perhaps i'm not doing something correctly afterwards? Would i not then just add a CSV writter after this?

I tried the solution @takashi provided and it worked like a dream. Be aware the XMLFragmenter Elements to Match field is case sensitive, this is what I did wrong initially.

FME 2019 template attached.

encodeandread.fmwt


Forum|alt.badge.img
  • Author
  • June 7, 2019
nielsgerrits wrote:

I tried the solution @takashi provided and it worked like a dream. Be aware the XMLFragmenter Elements to Match field is case sensitive, this is what I did wrong initially.

FME 2019 template attached.

encodeandread.fmwt

Yours did work like a dream! thank you very much. @takashi thank you as well!

Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings