title: Can we export query result in postgres using spooling command?
body: <p>I want to export query result in csv file. I used query select * from entity
  COPY (select * from entity) TO 'D:/text.csv' WITH DELIMITER AS '|' CSV HEADER;
  and it workd.. But I want to know if I can do it using spool command like we do it in oracle..</p>