docs.timescale.com-content icon indicating copy to clipboard operation
docs.timescale.com-content copied to clipboard

Documentation / Support for ANALYZE

Open nathansgreen opened this issue 8 years ago • 0 comments

I haven't been able to find any information about the ANALYZE command in your documentation. Here are a few of my unanswered questions:

  1. What is the behavior when I analyze a hypertable?
  2. Are all chunks analyzed?
  3. Should I disable auto-vacuum and just avoid analyze entirely?
  4. Is there a way to only analyze recent chunks or specific time windows rather than all chunks?

One reason I ask is that I recently had an analyze command run for 12 minutes on my test system. I would expect it to take 10 times longer if this were to go to production, so I need to know what is going on. Most of the data I work with arrives within an hour of being recorded; I assume there would be no benefit to analyzing hypertables that are built this way, but this wasn't clear to me from the documentation. However, I also have an infrequent occurrence where days-old, sometimes even weeks-old, data arrives, so I'd like to be able to run ANALYZE on an intelligent basis, if it will improve query performance.

nathansgreen avatar Nov 17 '17 14:11 nathansgreen