Skip to content

spurious error message when using qsv header #837

Answered by jqnatividad
njamescouk asked this question in Q&A
Discussion options

You must be logged in to vote

Rust's String type requires UTF-8 encoding, and since CSV files are Text Files that are primarily processed as Strings, they need to be UTF-8 encoded.

This is typically not a problem with other operating systems because UTF-8 is the de facto encoding standard.

Unfortunately, Window's default encoding is UTF-16LE, which presents a problems when you redirect/pipe qsv's output, as anytime you do so, the Windows operating system changes the encoding to UTF-16LE. Ironically, even Microsoft's own Excel cannot properly open a UTF-16LE encoded CSV file.

Regardless, the easiest way around this limitation is to use qsv's --output option which creates a UTF-8 encoded file and refrain from piping/red…

Replies: 2 comments 1 reply

Comment options

You must be logged in to vote
1 reply
@njamescouk
Comment options

Answer selected by njamescouk
Comment options

You must be logged in to vote
0 replies
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants