Pg_namespace
List PostgreSQL Functions with pg_proc
Jul 2, 2026 / · 10 min read · postgresql database administration sql queries functions pg_proc catalogs postgres dba pg_language pg_namespace ·List PostgreSQL Functions with pg_proc Where information_schema.routines delivers a SQL-standard view of functions and procedures — portable across databases but deliberately incomplete — pg_proc gives the full PostgreSQL catalog row: language, source code, argument modes, cost estimates, and the prokind flag that …
Read MoreList All PostgreSQL Triggers with Their State
Jun 7, 2026 / · 7 min read · pg_trigger triggers pg_class schema inventory administration pg_namespace ·List All PostgreSQL Triggers with Their State A disabled trigger is invisible until something it should have done goes missing. The audit row that never got written, the derived column that stopped updating, the constraint check that silently stopped firing — each traces back to a trigger left in the disabled state …
Read MorePostgreSQL Replica Identity for Logical Replication
Check Replica Identity Settings in PostgreSQL Logical replication in PostgreSQL requires each replicated table to have a replica identity. The replica identity tells PostgreSQL which columns to include in the WAL record for UPDATE and DELETE operations so the subscriber can identify the row being changed. If replica …
Read MoreList Installed Extensions in PostgreSQL
Apr 18, 2026 / · 4 min read · postgresql administration database pg_extension pg_available_extensions pg_description pg_namespace pg_stat_statements ·How to List Installed Extensions in PostgreSQL PostgreSQL extensions package additional functionality — data types, functions, operators, and index methods — that can be installed into a database with CREATE EXTENSION. Common examples include pg_stat_statements for query performance tracking, uuid-ossp for UUID …
Read MoreAudit Single vs Multi-Column Indexes in PostgreSQL
Apr 16, 2026 / · 4 min read · postgresql administration indexing database pg_index pg_class pg_namespace ·Audit Single vs Multi-Column Indexes in PostgreSQL Not all indexes are created equal. A single-column index covers one column and is simple to reason about. A multi-column (composite) index covers two or more columns and can serve a wider range of queries — but only when the leading columns match the query filter. As a …
Read MoreList All Schemas in Your PostgreSQL Database
Apr 13, 2026 / · 8 min read · postgresql administration database information_schema pg_namespace pg_class pg_tables ·How to List All Schemas in a PostgreSQL Database information_schema.schemata is the SQL-standard view for listing schemas, and it returns one row per schema in the current database that the connected role owns or holds a privilege on. Behind it sits pg_namespace, the system catalog that stores every schema with its …
Read MoreList PostgreSQL Partitioned Tables with SQL
List Partitioned and Ordinary Tables in PostgreSQL Before you change a retention job, plan a migration, or add a partition for next month, you need a plain list of which tables are partitioned and which are not. pg_class joined to pg_namespace gives that list for the whole database in one query, and a count from …
Read MoreList PostgreSQL Enum Types and Their Values with SQL
Apr 6, 2026 / · 4 min read · postgresql administration schema database data types pg_type pg_enum information_schema pg_namespace ·How to List All Enum Types in a PostgreSQL Database PostgreSQL supports user-defined enum types — a fixed ordered set of string values, each occupying four bytes on disk. Enums are common in application schemas for columns like status, role, or priority. Once created, their allowed values are managed in the database …
Read MoreList PostgreSQL Object Comments with SQL
Apr 4, 2026 / · 6 min read · postgresql administration schema database pg_description pg_statio_all_tables information_schema pg_class pg_index pg_namespace pg_proc ·List PostgreSQL Object Comments with SQL pg_description is where PostgreSQL keeps every comment attached with COMMENT ON, whether the target is a table, a column, an index, or a function. Psql shows these comments, and so does any tool that reads the catalog, which makes them a cheap way to keep a schema …
Read MoreEstimate PostgreSQL Table Bloat with SQL
Apr 1, 2026 / · 5 min read · postgresql performance vacuum optimization database pg_class pg_namespace pg_stats pg_attribute ·How to Estimate Table Bloat in PostgreSQL When you update or delete rows in PostgreSQL, the old row versions are not removed immediately. They stay in the table as dead tuples until VACUUM cleans them up. Over time, if VACUUM does not keep up, these dead rows pile up and the table grows larger than it needs to be. This …
Read More