{"Entry":{"collection":"guc","key":"gin_fuzzy_search_limit","name":"gin_fuzzy_search_limit","aliases":[],"metadata":{"baseline":false,"boot_human":"Not specified","boot_val":null,"category":"Client Connection Defaults / Other Defaults","category_zh":"","changed_in":["18"],"changes":[{"documentation_changed":false,"fields":{},"from":"8.1","status":"added","to":"8.2"},{"documentation_changed":true,"fields":{},"from":"8.2","status":"changed","to":"8.3"},{"documentation_changed":true,"fields":{},"from":"8.4","status":"changed","to":"9.0"},{"documentation_changed":true,"fields":{},"from":"9.0","status":"changed","to":"9.1"},{"documentation_changed":true,"fields":{},"from":"9.1","status":"changed","to":"9.2"},{"documentation_changed":true,"fields":{},"from":"9.2","status":"changed","to":"9.3"},{"documentation_changed":true,"fields":{},"from":"9.3","status":"changed","to":"9.4"},{"documentation_changed":true,"fields":{},"from":"9.4","status":"changed","to":"9.5"},{"documentation_changed":true,"fields":{},"from":"9.5","status":"changed","to":"9.6"},{"documentation_changed":true,"fields":{},"from":"9.6","status":"changed","to":"10"},{"documentation_changed":true,"fields":{},"from":"10","status":"changed","to":"11"},{"documentation_changed":true,"fields":{},"from":"13","status":"changed","to":"14"},{"documentation_changed":true,"fields":{},"from":"14","status":"changed","to":"15"},{"documentation_changed":true,"fields":{},"from":"16","status":"changed","to":"17"},{"documentation_changed":true,"fields":{"extra_desc":{"from":null,"to":"0 means no limit."}},"from":"17","status":"changed","to":"18"}],"content_hash":"6eceb4e476b6f1a3ab6dfe9003081ce83f5de2e34349ab16dd781952ba76f815","context":"","default_changed_in":[],"default_history":[{"from":"9.0","to":"19","value":"0"}],"derived_content_hash":"b0fe0d22fc8f11f78c28ddcb7061d3418dde10a1e3a6cfcfe52c0f2d731e1065","editorial":{"advice":{"olap":"For batch loads or broad searches, test gin_fuzzy_search_limit against ingestion latency, cleanup spikes, result completeness, and maintenance windows.","oltp":"Change gin_fuzzy_search_limit only after measuring the affected GIN maintenance or search path. Prefer an index-level override when one index, rather than the whole cluster, is exceptional.","small":"Do not raise gin_fuzzy_search_limit merely because the default is reached; bound memory and I/O bursts, and keep exact-query semantics unless approximation is explicitly acceptable."},"mechanism":["gin_fuzzy_search_limit sets the maximum allowed result for exact search by GIN. 0 means no limit. A positive limit makes broad GIN searches return a randomly chosen subset of matches, trading completeness for bounded work; zero preserves exact results.","gin_fuzzy_search_limit is a USER-context setting. An authorized role can change it for a session, while ALTER ROLE or ALTER DATABASE can establish a default for future sessions.","GIN behavior also depends on per-index storage parameters, work or maintenance memory, autovacuum, and the shape of indexed values and predicates."],"pitfalls":["Changing gin_fuzzy_search_limit in one session and assuming role defaults, database defaults, or other pooled sessions changed with it.","Applying a cluster-wide GIN value to fix one exceptional index instead of using its storage parameters.","Ignoring cleanup latency, I/O bursts, autovacuum interaction, or result completeness while tuning.","Enabling a positive limit without telling callers that exact searches may return an incomplete random subset."],"references":[{"title":"PostgreSQL 19 Beta 4: gin_fuzzy_search_limit","url":"https://www.postgresql.org/docs/19/runtime-config-client.html#GUC-GIN-FUZZY-SEARCH-LIMIT"},{"title":"PostgreSQL 19 release notes","url":"https://www.postgresql.org/docs/19/release-19.html"}],"related":["gin_pending_list_limit","maintenance_work_mem","work_mem","vacuum_cleanup_index_scale_factor","autovacuum_work_mem"],"summary":"gin_fuzzy_search_limit is the PostgreSQL setting that defines the maximum allowed result for exact search by GIN."},"enumvals":[],"first_version":"8.2","group":"Client Connection Defaults","group_slug":"client","imported_at":"2026-09-27T17:57:31.333529+08:00","intro_commit":{},"key":"gin_fuzzy_search_limit","last_version":"20","max_val":"","min_val":"","name":"gin_fuzzy_search_limit","position":160,"present_in":["8.2","8.3","8.4","9.0","9.1","9.2","9.3","9.4","9.5","9.6","10","11","12","13","14","15","16","17","18","19","20"],"repair_provenance":{"original_source_revision":"english-manuals:f942becd98667dac4bd516eeaac230c28d053d99add72266a9fcae9913f0bd93","receipt_sha256":"dd1854bd23b4601030a7d5a5089a3a9c60471c5d828e6cac1990770102d46950","repair":"wiki-repair-20261023"},"short_desc":"Soft upper limit of the size of the set returned by GIN index scans.","short_desc_zh":"","source_rev":"wiki-repair-20261023:5d9b6c9dbdf3333f2737281d9a82487ce2a22fd319ed145cdee073b999f285f7","unit":"","vartype":"integer"}},"Definition":{"Collection":"guc","Key":"gin_fuzzy_search_limit","SourceDatabase":"center","Version":"18","SourceTable":"guc","SourceKey":"gin_fuzzy_search_limit","SourceRevision":"wiki-repair-20261023:5d9b6c9dbdf3333f2737281d9a82487ce2a22fd319ed145cdee073b999f285f7","Facts":{"boot_val":"0","category":"Client Connection Defaults / Other Defaults","context":"user","description":"Soft upper limit of the size of the set returned by GIN index scans. For more information see Section 65.4.5.","description_zh":"GIN 索引扫描返回的集合尺寸的软上限。详见第 65.4.5 节。","description_zh_html":"\u003cp\u003e\n        GIN 索引扫描返回的集合尺寸的软上限。详见\u003ca class=\"xref\" href=\"/zh/docs/18/gin.html#GIN-TIPS\" title=\"65.4.5. GIN 提示和技巧\"\u003e第 65.4.5 节\u003c/a\u003e。\n       \u003c/p\u003e","doc":{"anchor":"GUC-GIN-FUZZY-SEARCH-LIMIT","file":"runtime-config-client.html","lang":"en","sha256":"6be6cc70f29eca4695dc43b2b2b94c75b7e0eaaa2c00273d7a98488917a7edb7","slug":"18"},"documented":true,"enumvals":null,"extra_desc":"0 means no limit.","lang":"en","max_val":"2147483647","metadata_version":"18","min_val":"0","name":"gin_fuzzy_search_limit","short_desc":"Sets the maximum allowed result for exact search by GIN.","source":"pg-settings-source-snapshot","translation_provenance":{"inputs":[{"kind":"current-pgdoc-translation","path":"/Users/vonng/pgsty/pgdoc/zh/18/html/runtime-config-client.html","sha256":"1882f8fd5576909c4fcc44af53077378871e05f5be67723f20fe300273024767"}],"kind":"same-version-pgdoc","locale":"zh-Hans","source_revision":"b1b500221dbe5437cfca004d6b04d3f6e422765d","version":"18"},"unit":null,"vartype":"integer","zh_from":"same-version-pgdoc"},"ManualEvidence":{"doc":{"anchor":"GUC-GIN-FUZZY-SEARCH-LIMIT","file":"runtime-config-client.html","lang":"en","sha256":"6be6cc70f29eca4695dc43b2b2b94c75b7e0eaaa2c00273d7a98488917a7edb7","slug":"18"}},"MeasuredEvidence":{"metadata_version":"18"}},"Text":{"Collection":"guc","Key":"gin_fuzzy_search_limit","SourceDatabase":"center","Version":"18","Locale":"en","Title":"gin_fuzzy_search_limit","Summary":"Soft upper limit of the size of the set returned by GIN index scans. For more information see Section 65.4.5.","BodyHTML":"\u003cp\u003eSoft upper limit of the size of the set returned by GIN index scans. For more information see Section 65.4.5.\u003c/p\u003e","SourceRevision":"wiki-repair-20261023:5d9b6c9dbdf3333f2737281d9a82487ce2a22fd319ed145cdee073b999f285f7","ContentHash":"f486666af148829a78e86f4b144d0b9732816a0f8998c905e4e02a1f98330881","Payload":{"description":"Soft upper limit of the size of the set returned by GIN index scans. For more information see Section 65.4.5."}},"RequestedLocale":"en","Fallback":false,"Versions":["10","11","12","13","14","15","16","17","18","19","20","8.2","8.3","8.4","9.0","9.1","9.2","9.3","9.4","9.5","9.6"],"Locales":["en","zh-Hans"],"Signatures":null,"Spellings":null,"SQLState":null,"Evidence":null}
