Loading…
0+ curated questions with the same answer shape every time: quick recap, deep dive, pitfalls, and follow-ups. Coverage includes .
pgx is the high-performance, feature-complete PostgreSQL driver for Go, preferred over lib/pq for all new projects. This module covers pgx v5's API (pgxpool.New for connection pooling, pgx.Connect for single connections, the pgx.Row/pgx.Rows scanning API), pgx's native PostgreSQL type support (pgtype.Text, pgtype.UUID, pgtype.JSONB — avoiding the reflect-based scanning overhead of database/sql), the COPY protocol for bulk inserts (orders of magnitude faster than individual INSERTs for batch data loading), LISTEN/NOTIFY for lightweight pub/sub using an existing PostgreSQL connection, pgxpool configuration (MaxConns, MinConns, HealthCheckPeriod — how to tune for a FastAPI-style throughput pattern), and the production workflow: reading query plans with EXPLAIN ANALYZE from Go, catching missing indexes with pg_stat_user_indexes. The interview differentiator is understanding when pgx's low-level control justifies the complexity over GORM.
Full catalog
Topics are ordered for learning. Within each topic, rows are numbered 1–0 globally so you always know where you are. Collapse topics if you want a lighter view — use Expand all when you need the full list again.
Numbers 1–0 follow the order we recommend — click any row to open the full answer, or use the sticky Next link at the bottom of each page to go Q1 → Q0.