Recent Posts

PSQL: Use Argument Indexes

less than 1 minute read

In Postgres, each of the arguments you specify in a select statement has a 1-based index tied to it. You can use these indexes in the order by and group by p...

PSQL: Types By Category

less than 1 minute read

Postgres has many types, each of which fall into a particular category. These categories include Array, Boolean, String, Numeric, Composite, etc. Each of the...

PSQL: Truncate Tables With Dependents

less than 1 minute read

If you have tables A and B where B has a foreign key referencing A, then trying to truncate A will result in something like this: