Skip to content

Dear Internet Explorer user: Your browser is no longer supported

Please switch to a modern browser such as Microsoft Edge, Mozilla Firefox or Google Chrome to view this website's content.

PostgreSQL: Add columns to a query table with variables

Posted 3rd July 2020

No comments

Generate a new column in your PostgreSQL database query from data in other columns or other tables.

Read the full story...

PostgreSQL: Store a PSQL COUNT query result as a Bash variable

Posted 5th June 2018

No comments

Use this nifty code to isolate the result of a PSQL COUNT query as a variable within a Bash script.

Read the full story...

Create a non-superuser role in PostgreSQL

Posted 18th April 2018

No comments

Use this easy procedure to establish a non-superuser role in PostgreSQL.

Read the full story...

Export a PostgreSQL query to a CSV

Posted 24th November 2017

2 comments

Export the contents of a database table to a CSV file using the psql PostgreSQL utility in PuTTY.

Read the full story...