{"id":48186438,"url":"https://github.com/ossc-db/pg_plan_advsr","last_synced_at":"2026-04-04T17:49:53.375Z","repository":{"id":51377347,"uuid":"170441535","full_name":"ossc-db/pg_plan_advsr","owner":"ossc-db","description":"PostgreSQL extension for automated execution plan tuning","archived":false,"fork":false,"pushed_at":"2024-03-12T04:56:43.000Z","size":511,"stargazers_count":89,"open_issues_count":1,"forks_count":12,"subscribers_count":18,"default_branch":"master","last_synced_at":"2024-03-26T05:09:58.887Z","etag":null,"topics":["adaptive","c","extension","optimization","plan-tuning","postgresql"],"latest_commit_sha":null,"homepage":"","language":"C","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ossc-db.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2019-02-13T04:41:57.000Z","updated_at":"2024-03-25T04:36:45.000Z","dependencies_parsed_at":"2022-09-14T01:33:00.056Z","dependency_job_id":null,"html_url":"https://github.com/ossc-db/pg_plan_advsr","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/ossc-db/pg_plan_advsr","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ossc-db%2Fpg_plan_advsr","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ossc-db%2Fpg_plan_advsr/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ossc-db%2Fpg_plan_advsr/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ossc-db%2Fpg_plan_advsr/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ossc-db","download_url":"https://codeload.github.com/ossc-db/pg_plan_advsr/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ossc-db%2Fpg_plan_advsr/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":31407655,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-04T10:20:44.708Z","status":"ssl_error","status_checked_at":"2026-04-04T10:20:06.846Z","response_time":60,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["adaptive","c","extension","optimization","plan-tuning","postgresql"],"created_at":"2026-04-04T17:49:53.269Z","updated_at":"2026-04-04T17:49:53.363Z","avatar_url":"https://github.com/ossc-db.png","language":"C","funding_links":[],"categories":[],"sub_categories":[],"readme":"pg_plan_advsr\n=============\n\npg_plan_advsr is a PostgreSQL extension that provides Automated execution plan tuning using feedback loop.\nThis extension might help you if you have an analytic query which has many joins and aggregates and you'd like to get an efficient plan to reduce execution time. This extension is intended to use in a plan tuning phase at the end of system development.\n\n* Note: This extension is intended to be used in a validation environment, not a commercial environment.\n* master branch for PostgreSQL 12 or above [![CI](https://github.com/ossc-db/pg_plan_advsr/workflows/CI/badge.svg)](https://github.com/ossc-db/pg_plan_advsr/actions?query=workflow%3ACI)\n\nContents\n========\n\nThis README contains the following sections:\n\n1. [Cookbook](#1-cookbook)\n2. [Objects created by the extension](#2-objects-created-by-the-extension)\n3. [Options](#3-options)\n4. [Usage](#4-usage)\n5. [Installation Requirements](#5-installation-requirements)\n6. [Installation](#6-installation)\n7. [Internals](#7-internals)\n8. [Limitations](#8-limitations)\n9. [Support](#9-support)\n10. [Author](#10-author)\n11. [Acknowledgments](#11-acknowledgments)\n\npg_plan_advsr was created by Tatsuro Yamada.\n\n\n1 Cookbook\n==========\n\nThis is a simple example of how to use pg_plan_advsr for auto execution plan tuning.\nMore detailed information will be provided in the sections\n[Options](#3-options) and [Usage](#4-usage).\n\nTry running regression tests inside the sql directory: pg_plan_advsr/sql.\nFirst, create a test table, etc. to execute init.sql. After that, run base.sql and observe the results of automatic plan tuning.\n\nAs shown below, you can see that a Nested Loop join during the first run has changed to a Hash join after tuning.\nThe error in the estimated number of rows should be zero, and the query execution time was successfully reduced.\n\nNote that ``base.sql`` will clear these tables and view such as hint_plan.hints, plan_repo.norm_queries, plan_repo.raw_queries, plan_repo.plan_history, and pg_store_plans view. So, please take care if you use it.\n\n\tpsql\n\t\\i init.sql\n\t\\i base.sql\n\n#### Before tuning (first run)\n\n\t                                                          QUERY PLAN\n\t-------------------------------------------------------------------------------------------------------------------------------\n\t Nested Loop  (cost=295.29..515.35 rows=1 width=16) (actual time=24.591..164.421 rows=9991 loops=1)\n\t   -\u003e  Hash Join  (cost=295.00..515.01 rows=1 width=16) (actual time=24.500..46.584 rows=10000 loops=1)\n\t         Hash Cond: ((a.c1 = b.c1) AND (a.c2 = b.c2))\n\t         -\u003e  Seq Scan on table_a a  (cost=0.00..145.00 rows=10000 width=8) (actual time=0.032..3.899 rows=10000 loops=1)\n\t         -\u003e  Hash  (cost=145.00..145.00 rows=10000 width=8) (actual time=24.359..24.359 rows=10000 loops=1)\n\t               Buckets: 16384  Batches: 1  Memory Usage: 519kB\n\t               -\u003e  Seq Scan on table_b b  (cost=0.00..145.00 rows=10000 width=8) (actual time=0.026..5.771 rows=10000 loops=1)\n\t   -\u003e  Index Scan using ind_c_c2 on table_c c  (cost=0.29..0.33 rows=1 width=8) (actual time=0.009..0.010 rows=1 loops=10000)\n\t         Index Cond: ((c2 = a.c2) AND (c2 \u003e= 10))\n\t         Filter: ((c1 \u003e 1) AND (c1 = a.c1))\n\t Planning Time: 3.952 ms\n\t Execution Time: 168.867 ms\n\t(12 rows)\n\n#### After tuning (final run)\n\t                                                          QUERY PLAN\n\t-------------------------------------------------------------------------------------------------------------------------------\n\t Hash Join  (cost=590.00..934.88 rows=9991 width=16) (actual time=37.030..74.904 rows=9991 loops=1)\n\t   Hash Cond: ((a.c1 = b.c1) AND (a.c2 = b.c2))\n\t   -\u003e  Hash Join  (cost=295.00..564.93 rows=9991 width=16) (actual time=17.751..40.944 rows=9991 loops=1)\n\t         Hash Cond: ((c.c1 = a.c1) AND (c.c2 = a.c2))\n\t         -\u003e  Seq Scan on table_c c  (cost=0.00..195.00 rows=9990 width=8) (actual time=0.060..7.318 rows=9991 loops=1)\n\t               Filter: ((c1 \u003e 1) AND (c2 \u003e= 10))\n\t               Rows Removed by Filter: 9\n\t         -\u003e  Hash  (cost=145.00..145.00 rows=10000 width=8) (actual time=17.658..17.660 rows=10000 loops=1)\n\t               Buckets: 16384  Batches: 1  Memory Usage: 519kB\n\t               -\u003e  Seq Scan on table_a a  (cost=0.00..145.00 rows=10000 width=8) (actual time=0.019..4.141 rows=10000 loops=1)\n\t   -\u003e  Hash  (cost=145.00..145.00 rows=10000 width=8) (actual time=19.249..19.250 rows=10000 loops=1)\n\t         Buckets: 16384  Batches: 1  Memory Usage: 519kB\n\t         -\u003e  Seq Scan on table_b b  (cost=0.00..145.00 rows=10000 width=8) (actual time=0.022..4.799 rows=10000 loops=1)\n\t Planning Time: 3.961 ms\n\t Execution Time: 78.294 ms\n\t(15 rows)\n\n\nSee: [Usage](#4-usage) for more details.\n\n2 Objects created by the extension\n==================================\n\nFunctions\n---------\n- FUNCTION ``pg_plan_advsr_enable_feedback()`` RETURNS void\n- FUNCTION ``pg_plan_advsr_disable_feedback()`` RETURNS void\n- FUNCTION ``plan_repo.get_hint(bigint)`` RETURNS text\n\t- If you give a pgsp_planid as an argument, it will return the hints to reproduce the plan based on pgsp_planid\n- FUNCTION ``plan_repo.get_extstat(bigint)`` RETURNS text\n\t- If you give a queryid as an argument, it will return the syntax for generating extended statistics. This function supports PG14 or above since it uses compute_query_id.\n\nTables\n------\n- ``plan_repo.plan_history``\n- ``plan_repo.norm_queries``\n- ``plan_repo.raw_queries``\n\nTable \"plan_repo.plan_history\"\n\n\t      Column         |            Type             | Description\n\t---------------------+-----------------------------+-------------------------------------------------------------------------------\n\t id                  | integer                     | Sequence as a primary key: nextval('plan_repo.plan_history_id_seq'::regclass)\n\t norm_query_hash     | text                        | MD5 based on normalized query text\n\t pgsp_queryid        | bigint                      | Queryid of pg_store_plans\n\t pgsp_planid         | bigint                      | Planid of pg_sotre_plans\n\t execution_time      | numeric                     | Execution time (ms) of this planid\n\t rows_hint           | text                        | Rows hint of this plan\n\t scan_hint           | text                        | Scan hint of this plan\n\t join_hint           | text                        | Join hint of this plan\n\t lead_hint           | text                        | Leading hint of this plan\n\t scan_rows_err       | numeric                     | Sum of estimation row error of scans\n\t scan_err_ratio      | numeric                     | Maximum estimation row error ratio of scans\n\t join_rows_err       | numeric                     | Sum of estimation row error of joins\n\t join_err_ratio      | numeric                     | Maximum estimation row error ratio of joins\n\t scan_cnt            | integer                     | Number of scan nodes in this plan\n\t join_cnt            | integer                     | Number of Join nodes in this plan\n\t application_name    | text                        | Application name of client tool such as \"psql\"\n\t timestamp           | timestamp without time zone | Timestamp of this record inserted\n\nTable \"plan_repo.norm_queries\"\n\n\t      Column       |           Type             | Description\n\t-------------------+----------------------------+-----------------------------------\n\t norm_query_hash   | text                       | MD5 based on normalized query text\n\t norm_query_string | text                       | Normalized query text\n\nTable \"plan_repo.raw_queries\"\n\n\t      Column      |            Type             | Description\n\t------------------+-----------------------------+----------------------------------------------------------------------------------------\n\t norm_query_hash  | text                        | MD5 based on normalized query text\n\t raw_query_id     | integer                     | Sequence of raw query text: nextval('plan_repo.raw_queries_raw_query_id_seq'::regclass)\n\t raw_query_string | text                        | Raw query text (not normalized)\n\t timestamp        | timestamp without time zone | Timestamp of this record inserted\n\n\nViews\n-----\n- ``plan_repo.plan_history_pretty``\n\n\tColumns are same as plan_history table, but number of decimal places are reduced for readability\n\n\n3 Options\n=========\n\n- ``pg_plan_advsr.enabled``\n\n\t\"ON\": Enable pg_plan_advsr.\n\tIt allows creating various hints for fixing row estimation errors and also for reproducing a plan.\n\tIt also stores them in the plan_history table. If you want to use \"auto plan tuning using feedback loop\", you have to execute below function \"pg_plan_advsr_enable_feedback().\n\tDefault setting is \"ON\".\n\n- ``pg_plan_advsr.quieted``\n\n\t\"ON\": Enable quiet mode.\n\tIt allows to disable emmiting the following messages when your EXPLAIN ANALYZE commmand finished.\n\n\t    pgsp_queryid\n\t    pgsp_planid\n\t    Execution time\n\t    Hints for current plan\n\t    Rows hint (feedback info)\n\t    and so on\n\n\tDefault setting is \"OFF\".\n\n- ``pg_plan_advsr.widely``\n\n\t\"ON\": Enable creating hints even if EXPLAIN command without ANALYZE option.\n\tIt allows creating various hints needed for reproducing a plan, but it doesn't create hints for fixing row estimation errors because there is no information of Actual rows.\n\tIt also stores them in the plan_history table. If you want to get hints to reproduce a plan, this option helps you.\n\tDefault setting is \"OFF\".\n\n- ``pg_plan_advsr_enable_feedback()``\n\n\tThis function allows you to use feedback loop for plan tuning.\n\tActually, it is a wrapper for these commands:\n\n\t    set pg_plan_advsr.enabled to on;\n\t    set pg_hint_plan.enable_hint_table to on;\n\t    set pg_hint_plan.debug_print to on;\n\t\n- ``pg_plan_advsr_disable_feedback()``\n\n\tThis function disables using feedback loop for plan tuning. It is a wrapper for these commands:\n\n\t    set pg_plan_advsr.enabled to on;\n\t    set pg_hint_plan.enable_hint_table to off;\n\t    set pg_hint_plan.debug_print to off;\n\n4 Usage\n=======\n\nTBA\n\nThere are four types of usage:\n\n- Displaying Execution Plan Characteristics\n- Automatic Execution Plan Tuning\n- Automatic Hint Clause Generation\n- Extended Statistics Suggestion\n\nDetails on how to use each are shown below.\n\n- **Displaying Execution Plan Characteristics**\n\n\tFirst, Make sure ``pg_plan_advsr.enabled to on``.\n\tThen, Execute EXPLAIN ANALYZE command (which is your query).\n\tYou can get the result with the ``DESCRIBE`` section appended, and you can see the number of joins, scans, errors in row count estimation, and so on.\n\n\te.g.\n\n\t\texplain (analyze, verbose) select * from t where a = 1 and b = 1;\n\t\t\n\t\t\t\t                                               QUERY PLAN\n\t\t--------------------------------------------------------------------------------------------------------\n\t\t Seq Scan on public.t  (cost=0.00..195.00 rows=100 width=8) (actual time=0.052..6.269 rows=100 loops=1)\n\t\t   Output: a, b\n\t\t   Filter: ((t.a = 1) AND (t.b = 1))\n\t\t   Rows Removed by Filter: 9900\n\t\t Query Identifier: -3455024416178978571\n\t\t Planning Time: 0.930 ms\n\t\t Execution Time: 9.136 ms\n\n\t\t DESCRIBE\n\t\t ------------------------\n\t\t application:    psql\n\t\t pgsp_queryid:   -3455024416178978571\n\t\t pgsp_planid:    3455841613\n\t\t join_cnt:       0\n\t\t join_rows_err:  0\n\t\t join_err_ratio: 0.00\n\t\t scan_cnt:       1\n\t\t scan_rows_err:  0\n\t\t scan_err_ratio: 0.00\n\t\t lead hint:      LEADING( t  )\n\t\t join hint:\n\t\t scan hint:      SEQSCAN(t)\n\t\t rows hint:\n\t\t(23 rows)\n\n- **For auto plan tuning**\n\n\tFirst, Run ``select pg_plan_advsr_enable_feedback();``.\n\tThen, Execute EXPLAIN ANALYZE command (which is your query) repeatedly until row estimation errors had vanished.\n\tFinally, You can check a result of the tuning by using the below queries:\n\n\t  select pgsp_queryid, pgsp_planid, execution_time, scan_hint, join_hint, lead_hint from plan_repo.plan_history order by id;\n\t\n\t  select queryid, planid, plan from pg_store_plans where queryid='your pgsp_queryid in plan_history' order by first_call;\n\t\n\tSee shell script file as an example: [JOB/auto_tune_31c.sh](https://github.com/ossc-db/pg_plan_advsr/blob/master/JOB/auto_tune_31c.sh)\n\n\tDemo of auto tuning (3x speed)\n\t![demo of auto tune](https://github.com/ossc-db/pg_plan_advsr/blob/master/JOB/img/auto_tune_31c_sql_demo.gif)\n\n\tIf you'd like to reproduce the execution plans on other environments, you'd be better to read the other.\n\n\n\tNote:\n\t\n\t- A plan may temporarily worse than an initial plan during auto tuning phase.\n\t- Use stable data for auto plan tuning. This extension doesn't get converged plan (the ideal plan for the data) if it was updating concurrently.\n\n- **For getting hints of current query**\n\n\tFirst, Run ``select pg_plan_advsr_disable_feedback();``.\n\tThen, Execute EXPLAIN ANALYZE command (which is your query).\n\tFinally, You can get hints by using the below queries:\n\n\t  select pgsp_queryid, pgsp_planid, execution_time, scan_hint, join_hint, lead_hint from plan_repo.plan_history order by id;\n\n\te.g.\n\t\n\t   pgsp_queryid | pgsp_planid | execution_time |                scan_hint                |     join_hint      |        lead_hint\n\t  --------------+-------------+----------------+-----------------------------------------+--------------------+-------------------------\n\t     4173287301 |  3707748199 |        265.179 | SEQSCAN(t2) SEQSCAN(x) INDEXSCAN(t1)    | HASHJOIN(t2 t1 x) +| LEADING( (t2 (x t1 )) )\n\t                |             |                |                                         | NESTLOOP(t1 x)     |\n\t     4173287301 |  1101439786 |          2.149 | SEQSCAN(x) INDEXSCAN(t1) INDEXSCAN(t2)  | NESTLOOP(t2 t1 x) +| LEADING( ((x t1 )t2 ) )\n\t                |             |                |                                         | NESTLOOP(t1 x)     |\n\n\t  # \\a\n\t  Output format is unaligned.\n\t  # \\t\n\t  Tuples only is on.\n\t\t\n\t  select plan_repo.get_hint(1101439786);\n\t\t\n\t  /*+\n\t  LEADING( ((x t1 )t2 ) )\n\t  NESTLOOP(t2 t1 x)\n\t  NESTLOOP(t1 x)\n\t  SEQSCAN(x) INDEXSCAN(t1) INDEXSCAN(t2)\n\t  */\n\t  --1101439786\n\t\n\tYou can use the hints to reproduce the execution plan anywhere. It also can be used to modify the execution plan by changing the hints manually.\n\n- **For getting extended statistics suggestion**\n\n\tThis feature is enabled when you use PG14 or above with pg_qualstats.\n\tFirst, Make sure ``pg_plan_advsr.enabled to on``.\n\tThen, Execute EXPLAIN ANALYZE command (which is your query).\n\tFinally, You can get extended statistics suggestion by using the below queries:\n\n\t  select * from plan_repo.get_extstat(queryid);\n\n\te.g.\n\n\t\t# select * from plan_repo.get_extstat(-3455024416178978571);\n\t\t                 suggest\n\t\t------------------------------------------\n\t\t CREATE STATISTICS ON a, b FROM public.t;\n\t\t(1 row)\n\n\t\n5 Installation Requirements\n===========================\n\npg_plan_advsr uses pg_hint_plan and pg_store_plans cooperatively.\n\n- PostgreSQL 12 or above\n- pg_hint_plan\n- pg_store_plans\n- pg_qualstats\n\t- if you'd like to use Extended statistic suggestion feature on PG14 or above\n- RHEL/CentOS/Rocky = 7.x or above\n\n\n6 Installation\n==============\n\nTBA\n\nThere are two methods to install the extension: Using building pg_plan_advsr manually.\n\n- ``Build and install (make \u0026\u0026 make install)``\n\n\t- Prerequisite for installation\n\t\t- Install postgresql-devel package if you installed PostgreSQL by rpm files\n\t\t- Set the PATH environment variable to pg_config of your PostgreSQL\n\t\n\tOperations\n\t\n\t1. git clone extensions\n\n\t\t```\n\t\t-- Required\n\t\tgit clone https://github.com/ossc-db/pg_hint_plan.git\n\t\tgit clone https://github.com/ossc-db/pg_store_plans.git\n\t\tgit clone https://github.com/ossc-db/pg_plan_advsr.git\n\n\t\t-- Optional: if you use Extended statistic suggestion feature on PG14 or above\n\t\tgit clone https://github.com/powa-team/pg_qualstats.git\n\t\t```\n\n\t2. git checkout\n\t\t\n\t\t##### Set the appropriate version of PostgreSQL for the VERSION variable. For example, If you use PG12, see below:\n\t\t```\n\t\texport VERSION=12\n\t\tcd pg_hint_plan\n\t\tgit checkout -b PG${VERSION} origin/PG${VERSION} \u0026\u0026 git checkout $(git describe --tag)\n\t\tcd ../pg_store_plans\n\t\tgit checkout $(git describe --tag)\n\t\t```\n\t\t\n\t3. build and install\n\n\t\t```\n\t\t-- Required\n\t\tcd ../pg_hint_plan\n\t\tmake -s \u0026\u0026 make -s install\n\t\tcp pg_stat_statements.c ../pg_plan_advsr/\n\t\tcp normalize_query.h ../pg_plan_advsr/\n\t\t\n\t\tcd ../pg_store_plans\n\t\tmake -s USE_PGXS=1 all install\n\t\tcp pgsp_json*.[ch] ../pg_plan_advsr/\n\t\t\n\t\tcd ../pg_plan_advsr\n\t\tgit describe --alway\n\t\tmake\n\t\tmake install\n\n\t\t-- Optional\n\t\tcd ../pg_qualstats\n\t\tmake\n\t\tmake install\n\t\t```\n\n\t4. edit PostgreSQL.conf\n\n\t\t```\n\t\tvi $PGDATA/postgresql.conf\n\n\t\t---- Add these lines -----------------------------------------------------\n\t\t-- Required\n\t\tshared_preload_libraries = 'pg_hint_plan, pg_plan_advsr, pg_store_plans'\n\t\tmax_parallel_workers_per_gather = 0\n\t\tmax_parallel_workers = 0\n\t\tcompute_query_id = on\n\n\t\tor\n\n\t\t-- Optional\n\t\tshared_preload_libraries = 'pg_hint_plan, pg_plan_advsr, pg_store_plans, pg_qualstats'\n\t\tmax_parallel_workers_per_gather = 0\n\t\tmax_parallel_workers = 0\n\t\tcompute_query_id = on\n\t\tpg_qualstats.resolve_oids = true\n\t\tpg_qualstats.sample_rate = 1\n\t\t-----------------------------------------------------------------------------------\n\n\t\t---- Consider tweak these numbers -------------------------------------------------\n\t\t-- Use a large value than join numbers of your query\n\t\tgeqo_threshold = 12 -\u003e 20\n\t\tfrom_collapse_limit = 8 -\u003e 20\n\t\tjoin_collapse_limit = 8 -\u003e 20\n\n\t\t-- Optional\n\t\trandom_page_cost = 4 -\u003e 1\n\t\t-----------------------------------------------------------------------------------\n\n\t5. run create extension commands on psql\n\n\t\t```\n\t\tpg_ctl start\n\t\tpsql\n\n\t\t-- Required\n\t\tcreate extension pg_hint_plan;\n\t\tcreate extension pg_store_plans;\n\t\tcreate extension pg_plan_advsr;\n\n\t\t-- Optional\n\t\tcreate extension pg_qualstats;\n\t\t```\n\t* You can try this extension with Join Order Benchmark as a example.\n\tSee: [how_to_setup.md in JOB directory](https://github.com/ossc-db/pg_plan_advsr/blob/master/JOB/how_to_setup.md)\n\n\n- ``Dockerfile (experimental)``\n\n\tOperations\n\n\t\t\\# cd pg_plan_advsr/docker\n\t\t\\# ./build.sh\n\n\tSee: build.sh and Dockerfile\n\n\n7 Internals\n===========\n\nTBA\n\nThese presentation materials are useful to know concepts and its architecture, and these show\na benchmark result by using Join order benchmark:\n\n* [AUTO PLAN TUNING USING FEEDBACK LOOP at PGConf.Eu 2018](https://www.postgresql.eu/events/pgconfeu2018/schedule/session/2132-auto-plan-tuning-using-feedback-loop/)\n\n* [AUTO PLAN TUNING USING FEEDBACK LOOP at PGConf.Russia 2019](https://pgconf.ru/en/2019/242844)\n\n\n8 Limitations\n=============\n\nNot supported\n------------\n - Handle InitPlans and SubPlans\n - Handle Append and MergeAppend\n - Fix bese-relation's estimated row error (This is pg_hint_plan's limitation)\n - Concurrent execution\n - Extended Statistics Suggestion for Grouping columuns and Expressions\n - Extended Statistics Suggestion on PG13 or below\n\nNot tested\n----------\n - Parallel query\n - Partitioned Table\n - JIT\n\nSee: [TODO file](https://github.com/ossc-db/pg_plan_advsr/blob/master/TODO)\n\npg_plan_advsr uses pg_hint_plan and pg_store_plans, it would be better to check these document to know their limitations.\n\n* [pg_hint_plan](https://github.com/ossc-db/pg_hint_plan/blob/master/doc/pg_hint_plan.html)\n* [pg_store_plans](https://github.com/ossc-db/pg_store_plans/blob/master/doc/index.html)\n\n\n9 Support\n=========\n\nIf you want to report a problem with pg_plan_advsr, please include the following information because we will analyze it by reproducing your problem:\n\n - Versions\n\t- PostgreSQL\n\t- pg_hint_plan\n\t- pg_store_plans\n - Query\n - DDL\n\t- CREATE TABLE\n\t- CREATE INDEX\n - Data (If possible)\n\nIf you have a problem or question or any kind of feedback, the preferred option is to open an issue on GitHub:\nhttps://github.com/ossc-db/pg_plan_advsr/issues\nThis requires a GitHub account.\nOf course, any Pull request welcome!\n\n\n10 Author\n=========\n\nTatsuro Yamada (yamatattsu at gmail dot com)\n\nCopyright (c) 2019-2024, NIPPON TELEGRAPH AND TELEPHONE CORPORATION\n\n\n11 Acknowledgments\n==================\n\nThe following individuals (in alphabetical order) have contributed to pg_plan_advsr as patch authors, reviewers, testers, advisers, or reporters of issues. Thanks a lot!\n\nAmit Langote  \nDavid Pitts  \nEtsuro Fujita  \nHironobu Suzuki  \nJulien Rouhaud  \nKaname Furutani  \nKyotaro Horiguchi  \nLaurenz Albe  \nNuko Yokohama  \nSam Xu  \n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fossc-db%2Fpg_plan_advsr","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fossc-db%2Fpg_plan_advsr","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fossc-db%2Fpg_plan_advsr/lists"}