Recent Posts

PSQL: Getting A Slice Of An Array

less than 1 minute read

Postgres has a very natural syntax for grabbing a slice of an array. You simply add brackets after the array declaring the lower and upper bounds of the slic...

PSQL: Defining Arrays

less than 1 minute read

In postgres, an array can be defined using the array syntax like so:

PSQL: Renaming A Table

less than 1 minute read

Using the alter table command in PostgreSQL, you can rename an existing table. This command will also update any references to the table such as via foreign ...

PSQL: Restart A Sequence

less than 1 minute read

In postgres, if you are truncating a table or doing some other sort of destructive action on a table in a development or testing environment, you may notice ...