Skip to content

Category

software development

Practical software engineering from a team lead: clean code, SOLID, refactoring, debugging, backend design and system architecture with Laravel and React.

PostgreSQL VACUUM vs VACUUM FULL Explained

10/31/2026

PostgreSQL VACUUM vs VACUUM FULL Explained

Learn the difference between PostgreSQL VACUUM and VACUUM FULL, how autovacuum works, and how to find and fix PostgreSQL table bloat without surprise locks.

By Muhammad Wilayat Shah

Read
How to Optimize PostgreSQL JOIN Performance

10/31/2026

How to Optimize PostgreSQL JOIN Performance

Slow SQL joins in PostgreSQL? Learn PostgreSQL join optimization step by step: read EXPLAIN ANALYZE, add the right indexes, fix statistics and verify the gains.

By Muhammad Wilayat Shah

Read
Four steps to stop long-running PostgreSQL queries: find them in pg_stat_activity by runtime, trace blockers with pg_blocking_pids, cancel then terminate the right pid, and prevent repeats with statement and idle-in-transaction timeouts

10/30/2026

How to Find and Terminate Long-Running PostgreSQL Queries

Month-end reports froze our ERP's invoice screen. Instead of restarting PostgreSQL, find the exact session in pg_stat_activity, trace blockers with pg_blocking_pids, cancel or terminate only that pid, then add per-role timeouts. Real PostgreSQL 17 output.

By Muhammad Wilayat Shah

Read