firtst release
Revisión | c9e741624f1695e955413003070b8e2142f4feae (tree) |
---|---|
Tiempo | 2019-01-17 14:16:50 |
Autor | Kyotaro Horiguchi <horiguchi.kyotaro@lab....> |
Commiter | Kyotaro Horiguchi |
Change copyright year to 2019
With some minor fixes in the document.
@@ -1,4 +1,4 @@ | ||
1 | -Copyright (c) 2012-2018, NIPPON TELEGRAPH AND TELEPHONE CORPORATION | |
1 | +Copyright (c) 2012-2019, NIPPON TELEGRAPH AND TELEPHONE CORPORATION | |
2 | 2 | All rights reserved. |
3 | 3 | |
4 | 4 | Redistribution and use in source and binary forms, with or without |
@@ -2,7 +2,7 @@ core.c and make_join_rel.c are parts of PostgreSQL Database Management System. | ||
2 | 2 | (formerly known as Postgres, then as Postgres95) |
3 | 3 | Copyright holders of those files are following organizations: |
4 | 4 | |
5 | -Portions Copyright (c) 1996-2018, PostgreSQL Global Development Group | |
5 | +Portions Copyright (c) 1996-2019, PostgreSQL Global Development Group | |
6 | 6 | |
7 | 7 | Portions Copyright (c) 1994, The Regents of the University of California |
8 | 8 |
@@ -1,7 +1,7 @@ | ||
1 | 1 | # |
2 | 2 | # pg_hint_plan: Makefile |
3 | 3 | # |
4 | -# Copyright (c) 2012-2018, NIPPON TELEGRAPH AND TELEPHONE CORPORATION | |
4 | +# Copyright (c) 2012-2019, NIPPON TELEGRAPH AND TELEPHONE CORPORATION | |
5 | 5 | # |
6 | 6 | |
7 | 7 | MODULES = pg_hint_plan |
@@ -1,5 +1,5 @@ | ||
1 | -# SPEC file for pg_store_plans | |
2 | -# Copyright(C) 2016-2018 NIPPON TELEGRAPH AND TELEPHONE CORPORATION | |
1 | +# SPEC file for pg_hint_plan | |
2 | +# Copyright(C) 2019 NIPPON TELEGRAPH AND TELEPHONE CORPORATION | |
3 | 3 | |
4 | 4 | %define _pgdir /usr/pgsql-9.5 |
5 | 5 | %define _bindir %{_pgdir}/bin |
@@ -20,7 +20,8 @@ | ||
20 | 20 | * mark_dummy_rel() |
21 | 21 | * restriction_is_constant_false() |
22 | 22 | * |
23 | - * Portions Copyright (c) 1996-2015, PostgreSQL Global Development Group | |
23 | + * | |
24 | + * Portions Copyright (c) 1996-2019, PostgreSQL Global Development Group | |
24 | 25 | * Portions Copyright (c) 1994, Regents of the University of California |
25 | 26 | * |
26 | 27 | *------------------------------------------------------------------------- |
@@ -102,6 +102,6 @@ PostgreSQL 9.2以降で動作します。</td></tr> | ||
102 | 102 | <a href="hint_list-ja.html">Appendix A. ヒント句一覧</a> |
103 | 103 | </div> |
104 | 104 | |
105 | -<p class="footer">Copyright (c) 2012-2014, NIPPON TELEGRAPH AND TELEPHONE CORPORATION</p> | |
105 | +<p class="footer">Copyright (c) 2012-2019, NIPPON TELEGRAPH AND TELEPHONE CORPORATION</p> | |
106 | 106 | </body> |
107 | 107 | </html> |
@@ -85,6 +85,6 @@ | ||
85 | 85 | <a href="hint_list-ja.html">Appendix A. hints list</a> |
86 | 86 | </div> |
87 | 87 | |
88 | -<p class="footer">Copyright (c) 2012, NIPPON TELEGRAPH AND TELEPHONE CORPORATION</p> | |
88 | +<p class="footer">Copyright (c) 2012-2019, NIPPON TELEGRAPH AND TELEPHONE CORPORATION</p> | |
89 | 89 | </body> |
90 | 90 | </html> |
@@ -628,10 +628,6 @@ postgres=# WHERE aid IN (SELECT bid FROM pgbench_accounts a2 LIMIT 10); | ||
628 | 628 | |
629 | 629 | postgres=# |
630 | 630 | </pre> |
631 | -<<<<<<< HEAD | |
632 | -一つのクエリで上記のような副問い合わせを複数使用している場合は、「ANY_subquery」と指定しても対象を特定できないため、ヒント句はエラーとなり無視されます。</br> | |
633 | -======= | |
634 | - | |
635 | 631 | <dt><h3>IndexOnlyScanヒント句</h3></dt> |
636 | 632 | <dd>ヒント句の対象となるテーブルにIndex Only Scanが可能なインデックスとIndex Only Scanが不可能なインデックスが同時に存在する場合、Index Only Scanが可能なインデックスをテーブルに対してIndexOnlyScanヒント句を追加で指定しないとIndex Scanが選択されることがあります。</dd> |
637 | 633 |
@@ -641,7 +637,6 @@ postgres=# | ||
641 | 637 | |
642 | 638 | <dt><h3>UNION に対する並列実行ヒント</h3></dt> |
643 | 639 | <dd>UNIONは直下のサブクエリが全て並列実行可能な場合にだけ並列実行を行います。一方ですべてのサブクエリが並列実行可能な場合は、そのうちの一つで並列実行を強制するとコスト比較の結果UNION全体が並列実行されることになります。ただし並列実行ヒントによる並列実行の禁止を行った場合はそのスキャンは並列実行不可となります。 |
644 | ->>>>>>> c6204a7... Added a notice in the manual. | |
645 | 640 | </dd> |
646 | 641 | <dt>IndexOnlyScanヒント句の指定(PostgreSQL 9.2以降)</dt> |
647 | 642 | <dd>ヒント句の対象となるテーブルにIndex Only Scanが可能なインデックスとIndex Only Scanが不可能なインデックスが存在する場合、Index Only Scanが可能なインデックスをテーブルと併せてIndexOnlyScanヒント句に指定しないとIndex Scanが選択されることがあります。</dd> |
@@ -697,9 +692,9 @@ postgres=# | ||
697 | 692 | <h2 id="requirement">動作環境</h2> |
698 | 693 | <dl> |
699 | 694 | <dt>PostgreSQL</dt> |
700 | - <dd>バージョン 9.1, 9.2, 9.3, 9.4</dd> | |
695 | + <dd>バージョン 9.5</dd> | |
701 | 696 | <dt>動作確認済みOS</dt> |
702 | - <dd>RHEL 6.5</dd> | |
697 | + <dd>RHEL 7.5</dd> | |
703 | 698 | </dl> |
704 | 699 | |
705 | 700 | <h2 id="seealso">関連項目</h2> |
@@ -713,19 +708,6 @@ postgres=# | ||
713 | 708 | <a href="pg_hint_plan-ja.html">pg_hint_plan</a> |
714 | 709 | </div> |
715 | 710 | |
716 | -<p class="footer">Copyright (c) 2012-2014, NIPPON TELEGRAPH AND TELEPHONE CORPORATION</p> | |
717 | - | |
718 | -<!-- | |
719 | -<script type="text/javascript"> | |
720 | -var gaJsHost = (("https:" == document.location.protocol) ? "https://ssl." : "http://www."); | |
721 | -document.write(unescape("%3Cscript src='" + gaJsHost + "google-analytics.com/ga.js' type='text/javascript'%3E%3C/script%3E")); | |
722 | -</script><script src="pg_statsinfo-ja_files/ga.js" type="text/javascript"></script> | |
723 | -<script type="text/javascript"> | |
724 | -try{ | |
725 | -var pageTracker = _gat._getTracker("UA-10244036-6"); | |
726 | -pageTracker._trackPageview(); | |
727 | -} catch(err) {} | |
728 | -</script> | |
729 | ---> | |
711 | +<p class="footer">Copyright (c) 2012-2019, NIPPON TELEGRAPH AND TELEPHONE CORPORATION</p> | |
730 | 712 | </body> |
731 | 713 | </html> |
@@ -312,29 +312,6 @@ postgres-# JOIN public.t1 pt ON (st.id=pt.id); | ||
312 | 312 | -> Seq Scan on t1 pt (cost=0.00..34.00 rows=2400 width=4) |
313 | 313 | (5 行) |
314 | 314 | |
315 | -<<<<<<< HEAD | |
316 | -postgres=#</pre> | |
317 | -</p> | |
318 | -<h2 id="restrictions">Restrictions</h2> | |
319 | -<h3>Limitations on multiple VALUES lists in FROM clauses</h3> | |
320 | -<p>All occurences of VALUES lists in FROM clauses in a query has the same name "*VALUES*" irrespective of aliases syntactically given to them or shown in explain descriptions. So it cannot be hinted at all if appeares twice or more in a target query. </p> | |
321 | -<h3>Hinting on inheritance children</h3> | |
322 | -<p>Inheritnce children cannot be hinted individually. They share the same hints on their parent.</p> | |
323 | - | |
324 | -<h3>Setting pg_hint_plan parameters by Set hints</h3> | |
325 | -<p>pg_hint_plan paramters changes the behavior of itself so some parameters doesn't work as expected.</p> | |
326 | -<ul> | |
327 | -<li>Hints to change enable_hint, enable_hint_tables are ignored, but they are reported as "used hints" in debug logs.</li> | |
328 | -<li>Setting debug_print and message_level works from midst of the processing of the target query.</li> | |
329 | -</ul> | |
330 | - | |
331 | - | |
332 | -<h2 id="technics">Technics to hint on desired targets</h2> | |
333 | -<h3>Hinting on objecects implicitly used in the target query</h3> | |
334 | -<p>Hints are effective on any objects with the target name even if they aren't aparent in the query, specifically objects in views. For that reason, you should create different views in which targetted objects have distinct aliases if you want to hint them differently from the first view.</p> | |
335 | -<p>In the following examples, the first query is assigning the same name "t1" on the two occurrences of the table1 so the hint SeqScan(t1) affects both scans. On the other hand the second assignes the different name 't3' on the one of them so the hint affects only on the rest one.</p> | |
336 | -<p>This mechanism also applies on rewritten queries by rules.</p> | |
337 | -======= | |
338 | 315 | <h3>Underlying tables of views or rules</h3> |
339 | 316 | <dd>Hints are not applicable on views itself, but they can affect the |
340 | 317 | queries within if the object names match the object names in the |
@@ -369,7 +346,6 @@ so it is hintable if it is the only VALUES in a query. Two or more | ||
369 | 346 | VALUES expressions in a query seems distinguishable looking its |
370 | 347 | explain result. But in reality it is mere a cosmetic and they are not |
371 | 348 | distinguisable. |
372 | ->>>>>>> c6204a7... Added a notice in the manual. | |
373 | 349 | <pre> |
374 | 350 | postgres=# CREATE VIEW view1 AS SELECT * FROM table1 <span class="strong">t1</span>; |
375 | 351 | CREATE TABLE |
@@ -430,18 +406,12 @@ postgres=# WHERE aid IN (SELECT bid FROM pgbench_accounts a2 LIMIT 10); | ||
430 | 406 | <h3>Using IndexOnlyScan hint (PostgreSQL 9.2 and later)</h3> |
431 | 407 | <p>You shoud explicitly specify an index that can perform index only scan if you put IndexOnlyScan hint on a table that have other indexes that cannot perform index only scan. Or pg_hint_plan may select them. </p> |
432 | 408 | |
433 | -<<<<<<< HEAD | |
434 | -<h3>Precaution points for NoIndexScan hint (PostgreSQL 9.2 and later)</h3> | |
435 | -<p>NoIndexScan hint involes NoIndexOnlyScan.</p> | |
436 | - | |
437 | -======= | |
438 | 409 | <h3>Parallel hint and UNION</h3> |
439 | 410 | <dd>A UNION can run in parallel only when all underlying subqueries |
440 | 411 | are parallel-safe. Conversely enforcing parallel on any of |
441 | 412 | the subqueries let a parallel-executable UNION run in |
442 | 413 | parallel. Meanwhile, a parallel hint with zero workers hinhibits a scan |
443 | 414 | from executed in parallel.</dd> |
444 | ->>>>>>> c6204a7... Added a notice in the manual. | |
445 | 415 | |
446 | 416 | <h2 id="errors">Errors of hints</h2> |
447 | 417 | <p>pg_hint_plan stops parsing on any error and uses hints already parsed on the most cases. Followings are the typical errors.</p> |
@@ -477,9 +447,9 @@ from executed in parallel.</dd> | ||
477 | 447 | <h2 id="requirement">Requirements</h2> |
478 | 448 | <dl> |
479 | 449 | <dt>PostgreSQL versions tested</dt> |
480 | - <dd>Version 9.1, 9.2, 9.3, 9.4</dd> | |
450 | + <dd>Version 9.5</dd> | |
481 | 451 | <dt>OS versions tested</dt> |
482 | - <dd>RHEL 6.5, 7.0</dd> | |
452 | + <dd>RHEL 7.5</dd> | |
483 | 453 | </dl> |
484 | 454 | |
485 | 455 | <h2 id="seealso">See also</h2> |
@@ -493,19 +463,6 @@ from executed in parallel.</dd> | ||
493 | 463 | <a href="pg_hint_plan.html">pg_hint_plan</a> |
494 | 464 | </div> |
495 | 465 | |
496 | -<p class="footer">Copyright (c) 2012, NIPPON TELEGRAPH AND TELEPHONE CORPORATION</p> | |
497 | - | |
498 | -<!-- | |
499 | -<script type="text/javascript"> | |
500 | -var gaJsHost = (("https:" == document.location.protocol) ? "https://ssl." : "http://www."); | |
501 | -document.write(unescape("%3Cscript src='" + gaJsHost + "google-analytics.com/ga.js' type='text/javascript'%3E%3C/script%3E")); | |
502 | -</script><script src="pg_statsinfo-ja_files/ga.js" type="text/javascript"></script> | |
503 | -<script type="text/javascript"> | |
504 | -try{ | |
505 | -var pageTracker = _gat._getTracker("UA-10244036-6"); | |
506 | -pageTracker._trackPageview(); | |
507 | -} catch(err) {} | |
508 | -</script> | |
509 | ---> | |
466 | +<p class="footer">Copyright (c) 2012-2019, NIPPON TELEGRAPH AND TELEPHONE CORPORATION</p> | |
510 | 467 | </body> |
511 | 468 | </html> |
@@ -6,8 +6,8 @@ | ||
6 | 6 | * src/backend/optimizer/path/joinrels.c |
7 | 7 | * make_join_rel() |
8 | 8 | * |
9 | - * Portions Copyright (c) 2013-2018, NIPPON TELEGRAPH AND TELEPHONE CORPORATION | |
10 | - * Portions Copyright (c) 1996-2015, PostgreSQL Global Development Group | |
9 | + * Portions Copyright (c) 2013-2019, NIPPON TELEGRAPH AND TELEPHONE CORPORATION | |
10 | + * Portions Copyright (c) 1996-2019, PostgreSQL Global Development Group | |
11 | 11 | * Portions Copyright (c) 1994, Regents of the University of California |
12 | 12 | * |
13 | 13 | *------------------------------------------------------------------------- |
@@ -6,7 +6,7 @@ | ||
6 | 6 | * This header file is created from pg_stat_statements.c to implement |
7 | 7 | * normalization of query string. |
8 | 8 | * |
9 | - * Portions Copyright (c) 2008-2014, PostgreSQL Global Development Group | |
9 | + * Portions Copyright (c) 2008-2019, PostgreSQL Global Development Group | |
10 | 10 | */ |
11 | 11 | #ifndef NORMALIZE_QUERY_H |
12 | 12 | #define NORMALIZE_QUERY_H |
@@ -4,7 +4,7 @@ | ||
4 | 4 | * do instructions or hints to the planner using C-style block comments |
5 | 5 | * of the SQL. |
6 | 6 | * |
7 | - * Copyright (c) 2012-2014, NIPPON TELEGRAPH AND TELEPHONE CORPORATION | |
7 | + * Copyright (c) 2012-2019, NIPPON TELEGRAPH AND TELEPHONE CORPORATION | |
8 | 8 | * |
9 | 9 | *------------------------------------------------------------------------- |
10 | 10 | */ |
@@ -4,7 +4,7 @@ | ||
4 | 4 | * |
5 | 5 | * Part of pg_stat_statements.c in PostgreSQL 9.5. |
6 | 6 | * |
7 | - * Copyright (c) 2008-2015, PostgreSQL Global Development Group | |
7 | + * Copyright (c) 2008-2019, PostgreSQL Global Development Group | |
8 | 8 | * |
9 | 9 | *------------------------------------------------------------------------- |
10 | 10 | */ |