Home / Companies / Tiger Data / Blog / Post Details
Content Deep Dive

How We Fixed Long-Running PostgreSQL now( ) Queries (and Made Them Lightning Fast)

Blog post from Tiger Data

Post Details
Company
Date Published
Author
Sven Klemm
Word Count
1,564
Company Posts That Month
7
Language
English
Hacker News Points
18
Post removed?
No
Summary

TimescaleDB has optimized its `now()` function to improve query performance, particularly in hypertables with many chunks. The optimization works by rewriting the constraint to make the `now()` expression constifiable during plan-time chunk exclusion, reducing planning time and speeding up queries. This improvement is available in TimescaleDB 2.7 and will be further expanded in version 2.8 to support intervals of months and years. The optimization significantly improves query performance, with performance improvements scaling with the total number of chunks in hypertables, resulting in speeds up to 401x faster than the previous version for a total of 20,000 chunks. Users can upgrade to TimescaleDB 2.7 automatically if using Timescale Cloud or manually if self-managing their instance.

Trends Found in this Post

No tracked trend matches for this post yet.

Use This Data

Use this post, company, and trend context to find content marketing opportunities, perform competitive analysis, or address product feature gaps via the Plushcap MCP server or the Plushcap API.