--- warning: DO NOT CHANGE THIS MANUALLY, THIS IS GENERATED BY https://github.com/duckdb/community-extensions repository, check README there title: query_condition_cache excerpt: | DuckDB Community Extensions This extension provides a cache for query conditions, which is useful for repeated-query workloads like metrics monitoring dashboards, log investigations, etc. extension: name: query_condition_cache description: This extension provides a cache for query conditions, which is useful for repeated-query workloads like metrics monitoring dashboards, log investigations, etc. version: 0.2.0 language: C++ build: cmake license: MIT excluded_platforms: "wasm_mvp;wasm_eh;wasm_threads;windows_amd64_rtools;windows_amd64;windows_amd64_mingw" maintainers: - Andrewtangtang - peterxcli - dentiny repo: github: dentiny/duckdb-query-condition-cache ref: e6af277259ecd0a28db21675deaa47792900d7dc docs: hello_world: | SELECT * FROM condition_cache_build('t', 'val = 42 AND msg LIKE ''%2'''); extended_description: | This extension enhances DuckDB core capability and improves query performance for repeated-query workloads by caching the query conditions. extension_star_count: 19 extension_star_count_pretty: 19 extension_download_count: 12296 extension_download_count_pretty: 12.3k image: '/images/community_extensions/social_preview/preview_community_extension_query_condition_cache.png' layout: community_extension_doc --- ### Compatibility Matrix This table covers all DuckDB releases that have not reached [end-of-life](https://duckdb.org/release_calendar), including LTS releases, and shows the 2 most recent patch releases of each. Older patch releases are not listed, but the extension may be available for them as well.
| Platform | 1.4.4 | 1.4.5 | 1.5.5 | 1.5.6 | 2.0.0 | | :--- | :---: | :---: | :---: | :---: | :---: | | Linux AMD64 | ❌ | ❌ | ✅ | ✅ | ✅ | | Linux ARM64 | ❌ | ❌ | ✅ | ✅ | ✅ | | macOS AMD64 | ❌ | ❌ | ✅ | ✅ | ✅ | | macOS ARM64 | ❌ | ❌ | ✅ | ✅ | ✅ | | Windows AMD64 | ❌ | ❌ | ❌ | ❌ | ❌ | | Windows ARM64 | ❌ | ❌ | ❌ | ❌ | ❌ | | WebAssembly | ❌ | ❌ | ❌ | ❌ | ❌ | ### Installing and Loading ```sql INSTALL {{ page.extension.name }} FROM community; LOAD {{ page.extension.name }}; ``` {% if page.docs.hello_world %} ### Example ```sql {{ page.docs.hello_world }}``` {% endif %} {% if page.docs.extended_description %} ### About {{ page.extension.name }} {{ page.docs.extended_description }} {% endif %} ### Added Functions
| function_name | function_type | description | comment | examples | |-----------------------------|---------------|-------------------------------------------------------------------------------------------------------------|---------|----------------------------------------------------------------------------| | __condition_cache_filter | scalar | Internal optimizer filter that checks whether the cache permits scanning a row ID's vector. | NULL | [SELECT __condition_cache_filter(0);] | | condition_cache_build | table | Builds or replaces a query condition cache for rows in a table that match a SQL predicate. | NULL | [SELECT * FROM condition_cache_build('events', 'event_type = ''error''');] | | condition_cache_info | table | Returns row-group and vector coverage for a cached table and SQL predicate, or zeroes when no entry exists. | NULL | [SELECT * FROM condition_cache_info('events', 'event_type = ''error''');] | | condition_cache_reset_stats | scalar | Resets query condition cache hit and access counters and returns true. | NULL | [SELECT condition_cache_reset_stats();] | | condition_cache_stats | table | Returns query condition cache memory use, hit count, and access count. | NULL | [SELECT * FROM condition_cache_stats();] | ### Overloaded Functions
This extension does not add any function overloads. ### Added Types
This extension does not add any types. ### Added Settings
| name | description | input_type | scope | aliases | typed_value | |---------------------------|---------------------------------------------------------|------------|--------|---------|-------------| | temp_directory | Set the directory to which temporary files are written. | VARCHAR | GLOBAL | [] | post.db.tmp | | use_query_condition_cache | Enable automatic query condition cache build and apply | BOOLEAN | GLOBAL | [] | true |