export table to csv on postgres

前端 未结 5 1199
甜味超标
甜味超标 2021-02-05 13:56

How can I export a table to .csv in Postgres, when I\'m not superuser and can\'t use the copy command?

I can still import the data to postgres

5条回答
  •  隐瞒了意图╮
    2021-02-05 15:03

    The easiest way would indeed be a COPY to stdout I think. If you can't do this, how about using pg_dump and then transform the output file with sed, AWK or even a text editor? This should work even with search and replace in an acceptable amount of time :)

提交回复
热议问题