postgresql - Copy From csv to postgres -
postgresql - Copy From csv to postgres -
i having problem using re-create command in postgresql import info in csv file. first created table in postgresql next code.
create table sfmap ( address varchar(100), city varchar(50), state varchar(5), zip varchar(6), county varchar(20) )
i used next code re-create info in table.
copy sfmap(address, city, state, county) 'h:\sfmap.csv' delimiter ',' csv header
every time this, follow error message.
error: not open file "h:\sfmap.csv" reading: no such file or directory sql state: 58p01
i sure location of file correct. have tried using forwards slash, 2 backwardslashes. don't see doing wrong.
copy command must run postgres superuser. might worth checking that.
postgresql csv
Comments
Post a Comment