Recent Posts

(TIL) PSQL: Storing Emails With citext

less than 1 minute read

Email addresses should be treated as case-insensitive because they are. If a user is trying to sign in with their email address, we shouldn’t care if they ty...

(TIL) 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...

(TIL) 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 ...

(TIL) 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 ...