Cancel a long-running PostgreSQL query by PID
SELECT pg_cancel_backend(<pid>);
Create a new PostgreSQL user and database
Show columns, types, and constraints of a table
Export a PostgreSQL table to a CSV file
Find rows with duplicate values in a column