In this article we will see how we can implement data anonymization and masking in a PostgreSQL 14 database using the PostgreSQL Anonymizer extension. We will cover the installation process, setting up masking rules, as well as the specifics that… read more
How to do Bulk Export Import in PostgreSQL (pg_dump)
For those of us who come from the world of Oracle and Data Pump (expdp/impdp), in this article we will look at the corresponding PostgreSQL tools pg_dump and pg_restore. These tools allow us to run these processes with parallel threads,… read more
How to find Missing Indexes in PostgreSQL
Those of us who come from the world of SQL Server are used to the Missing Index DMVs (sys.dm_db_missing_index_details, sys.dm_db_missing_index_group_stats), which give us the CREATE INDEX command ready along with Avg User Impact and Equality/Inequality/Include columns. In PostgreSQL, the default… read more
How to do Performance Testing in PostgreSQL with pgbench
pgbench is one of the most useful tools for PostgreSQL. It is used for benchmarking and stress testing the database, simulating multiple simultaneous transactions (TPS). In this article we will see how we can set it up, run the… read more
How to find alerts in PostgreSQL through Plain Text Logs with a query
As Database Administrators, we are used to reading alerts as normal tables from v$diag_alert_ext with simple SQL queries in environments like Oracle. In PostgreSQL, things are a little different, by default its logs are plain text… read more
How to see how much Indexes are used in PostgreSQL
In every database, indexes are essential for the speed of SELECT queries. However, each index we create has a cost, it takes up disk space, burdens memory and delays INSERT, UPDATE and DELETE operations, since the… read more
How to find the size of tables in a PostgreSQL database
When managing production databases, sooner or later there will come a time when the available disk space starts to decrease dangerously. The crucial question then is which table is eating up the space. In this article we will see… read more
How to check permissions, Grants and Default Privileges in PostgreSQL
In managing a PostgreSQL database, access control is one of the most critical parts. Unlike other RDBMSs that have single system views for all permissions, PostgreSQL relies on System Catalogs and special… read more
How to Backup and Restore PostgreSQL using the pgBackrest tool
As we have seen in previous articles, in older versions of PostgreSQL before version 17 there was no possibility for block level backup, as a result we could not do differential and incremental backups and we would have to take them every day... read more
