New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Bug]: Query does not use index on partially compressed chunks #5432
Comments
Duplicate of #5413 |
This is not a duplicate rather related to #5413. #5413 reports that the index is not being used even when the query is only on the uncompressed chunks of a compressed table. This is not expected and it is probably a bug in a certain case (at the time of this comment, #5413 is still unverified). But this issue, 5432, reports that the when there is a mix of compressed and uncompressed chunks and if a query has to scan both type of chunks, a seq scan is always chosen. A better plan is to use seq scan for the compressed chunks and index scan for the uncompressed chunks. |
@antekresic Verified and reopened this bug, Sorry for the confusion earlier! |
This was previously disabled as no data resided on the uncompressed chunk once it was compressed, but this is not the case anymore with partially compressed chunks. Fixes timescale#5432 Co-authored-by: Ante Kresic <ante.kresic@gmail.com>
This was previously disabled as no data resided on the uncompressed chunk once it was compressed, but this is not the case anymore with partially compressed chunks. Fixes timescale#5432 Co-authored-by: Ante Kresic <ante.kresic@gmail.com>
This was previously disabled as no data resided on the uncompressed chunk once it was compressed, but this is not the case anymore with partially compressed chunks, so we enable indexscan for the uncompressed chunk again. Fixes timescale#5432 Co-authored-by: Ante Kresic <ante.kresic@gmail.com>
This was previously disabled as no data resided on the uncompressed chunk once it was compressed, but this is not the case anymore with partially compressed chunks, so we enable indexscan for the uncompressed chunk again. Fixes timescale#5432 Co-authored-by: Ante Kresic <ante.kresic@gmail.com>
This was previously disabled as no data resided on the uncompressed chunk once it was compressed, but this is not the case anymore with partially compressed chunks, so we enable indexscan for the uncompressed chunk again. Fixes timescale#5432 Co-authored-by: Ante Kresic <ante.kresic@gmail.com>
This was previously disabled as no data resided on the uncompressed chunk once it was compressed, but this is not the case anymore with partially compressed chunks, so we enable indexscan for the uncompressed chunk again. Fixes timescale#5432 Co-authored-by: Ante Kresic <ante.kresic@gmail.com>
This was previously disabled as no data resided on the uncompressed chunk once it was compressed, but this is not the case anymore with partially compressed chunks, so we enable indexscan for the uncompressed chunk again. Fixes timescale#5432 Co-authored-by: Ante Kresic <ante.kresic@gmail.com>
This was previously disabled as no data resided on the uncompressed chunk once it was compressed, but this is not the case anymore with partially compressed chunks, so we enable indexscan for the uncompressed chunk again. Fixes #5432 Co-authored-by: Ante Kresic <ante.kresic@gmail.com>
This was previously disabled as no data resided on the uncompressed chunk once it was compressed, but this is not the case anymore with partially compressed chunks, so we enable indexscan for the uncompressed chunk again. Fixes timescale#5432 Co-authored-by: Ante Kresic <ante.kresic@gmail.com> (cherry picked from commit 5633960)
This was previously disabled as no data resided on the uncompressed chunk once it was compressed, but this is not the case anymore with partially compressed chunks, so we enable indexscan for the uncompressed chunk again. Fixes timescale#5432 Co-authored-by: Ante Kresic <ante.kresic@gmail.com> (cherry picked from commit 5633960)
This was previously disabled as no data resided on the uncompressed chunk once it was compressed, but this is not the case anymore with partially compressed chunks, so we enable indexscan for the uncompressed chunk again. Fixes #5432 Co-authored-by: Ante Kresic <ante.kresic@gmail.com> (cherry picked from commit 5633960)
This was previously disabled as no data resided on the uncompressed chunk once it was compressed, but this is not the case anymore with partially compressed chunks, so we enable indexscan for the uncompressed chunk again. Fixes #5432 Co-authored-by: Ante Kresic <ante.kresic@gmail.com> (cherry picked from commit 5633960)
What type of bug is this?
Performance issue
What subsystems and features are affected?
Compression
What happened?
When inserting into a hypertable with defined indexes and compressed chunks, querying does not use index scans where it seems appropriate for the uncompressed portion of the partially compressed chunk.
It seems to always default to sequential scans even if filtering 1000s of rows while an index exists which ideally should be used.
TimescaleDB version affected
main branch
PostgreSQL version used
14.5
What operating system did you use?
Ubuntu 22.04.1
What installation method did you use?
Source
What platform did you run on?
On prem/Self-hosted
Relevant log output and stack trace
How can we reproduce the bug?
Running analyze on the hypertable or chunk does not help.
The text was updated successfully, but these errors were encountered: