(TIL) SQL: Count Records By Type
If you have a table with some sort of type column on it, you can come up with a count of the records in that table by type. You just need to take advantage o...
If you have a table with some sort of type column on it, you can come up with a count of the records in that table by type. You just need to take advantage o...
The pg_typeof() function allows you to determine the data type of anything in Postgres.
Consider the scenario where you are trying to drop a database, but there are existing connections.
The pg_stat_activity table can be used to determine what connections there currently are to the PostgreSQL server and to a particular database. To see the pr...
Generally you want your SQL statements to run against your database as quickly as possible. For those times when you are doing some sort of debugging or just...