Skip to content
← All issues

Readyset Weekly: Issue 4

Why Your Indexes Aren’t Helping

Indexes are supposed to accelerate queries, but poor design can bloat storage and slow things down. Make them work smarter, not harder.

In PostgreSQL:

  • Identify deadweight indexes with pg_stat_user_indexes by checking for low idx_scan counts.
  • Reclaim wasted space by using pgstattuple to detect index bloat.
  • Optimize multicolumn indexes by prioritizing selective columns (Postgres uses a left-most prefix strategy).
  • Prevent overlap by inspecting pg_indexes for redundancy.
  • Leverage partial indexes for queries with targeted WHERE clauses.
  • Choose BRIN indexes for large, sequential datasets like time series or IDs.

In MySQL:

  • Use EXPLAIN to verify index usage and confirm that they are optimizing queries.
  • Spot full table scans by checking for NULL under the key column.
  • Monitor inefficient lookups with Handler_read_rnd_next (high values suggest table scans).
  • Align composite indexes with query patterns for maximum efficiency.
  • Be mindful of inefficient automatic indexes created during foreign keys, unique constraints, and primary key definitions.
  • Reclaim wasted space after heavy deletes with OPTIMIZE TABLE.

These are just a few ways to optimize indexing. For deeper insights, explore PostgreSQL Indexing Best Practices Guide and Understanding MySQL Indexes: Types, Benefits, and Best Practices.

🔍 What We’re Watching in the Database Ecosystem

MySQL 9.3! Thank you for your contributions! MySQL 9.3, the latest innovation release, introduces key advancements in database optimization, enhanced developer productivity, and seamless integration capabilities. We're proud to have contributed to this release, alongside the broader community. As the database landscape evolves, MySQL continues to innovate, ensuring its place in modern, scalable applications.

PostgreSQL 18 Beta 1 Released! PostgreSQL 18 Beta 1 introduces significant performance improvements with asynchronous I/O, enhanced indexing, and streamlined major version upgrades, alongside new developer, security, and monitoring features. The community is encouraged to test these innovations ahead of the final release expected in late 2025. Postgres continues to strengthen its reputation for reliability and scalability, affirming its role as a key player in modern database architecture.

Databricks Agrees to Acquire Neon Databricks is acquiring Neon, a startup that offers a serverless, open-source PostgreSQL database, for approximately $1 billion. This move signals the shift towards serverless, cloud native solutions, underscoring the industry’s focus on scalable, developer-friendly database architectures.

In Case You Missed It

📅 Mark Your Calendar: We are proud to sponsor PGDay Blumenau on May 24th. Our very own Marcelo and Bianchi will be representing the Readyset.io team and are excited to connect with the Postgres community. If you're attending or in the area, reply and let us know!

Get Readyset Weekly in your inbox

One email a week — what shipped, what we learned, and what is worth reading.