Beefy Boxes and Bandwidth Generously Provided by pair Networks
good chemistry is complicated,
and a little bit messy -LW
 
PerlMonks  

PostgreSQL connection set in UTF8

by LorenzoLu (Initiate)
on Nov 05, 2019 at 17:00 UTC ( #11108335=perlquestion: print w/replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    open(DATA_FILE,"<:utf8",$filename) || die print "can not open reading 
    +file --> \"$filename\"";
    open DB, '| /opt/postgresql-9.4/bin/psql -h ... (here all the paramete
    +rs)'
    print DB "copy $table($header) from STDIN CSV;\n";
    while ( my $line = <DATA_FILE>) {
       print DB "$line";
    }
    

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: perlquestion [id://11108335]
Approved by Corion
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others contemplating the Monastery: (2)
As of 2020-12-05 15:04 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    How often do you use taint mode?





    Results (64 votes). Check out past polls.

    Notices?