I want to copy table from postgis database to the PC hard drive (format can be .txt .xls .csv or whatever). How it can be done?
1 Answer
Use the SQL COPY command to write to the file system of the database server.
COPY tbl TO '/path/to/file/tbl.sql';
There are lots of options to adapt the output format.
Have a look at the \copy meta-command of psql if you need to copy from a remote server to the local disk.