Beefy Boxes and Bandwidth Generously Provided by pair Networks
Problems? Is your data what you think it is?
 
PerlMonks  

Re^3: Stupid UTF-8 issue with CSV file

by glasswalk3r (Friar)
on Dec 05, 2016 at 20:00 UTC ( [id://1177280]=note: print w/replies, xml ) Need Help??


in reply to Re^2: Stupid UTF-8 issue with CSV file
in thread Stupid UTF-8 issue with CSV file

What happens if you force the file to be written as UTF-8?

open(my $output, '>:utf8', $filename) or die "Cannot write $filename: +$!";

Considering that the CVS data is in UTF-8, which is a good idea anyway unless you have restrictions for it.

You should be using open with three arguments anyway, it is a good practice.

Alceu Rodrigues de Freitas Junior
---------------------------------
"You have enemies? Good. That means you've stood up for something, sometime in your life." - Sir Winston Churchill

Replies are listed 'Best First'.
Re^4: Stupid UTF-8 issue with CSV file
by ikegami (Patriarch) on Dec 06, 2016 at 06:18 UTC

    What he has is equivalent.

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://1177280]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others having a coffee break in the Monastery: (4)
As of 2024-04-26 00:13 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found