Advertisement
ellenallhatatlan

Views_only_no_fxns

Jun 20th, 2021
20
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 4.86 KB | None | 0 0
  1. Views only, no functions - dbfiddle: https://dbfiddle.uk/?rdbms=postgres_13&fiddle=2cb60f2675eae120cfc5552017f1de90
  2.  
  3. QUERY PLAN
  4. --------------------------------------------------------------------------------------------------------------------------------------------------------------
  5. Result (cost=303629.51..303629.53 rows=1 width=32) (actual time=1572.903..1574.726 rows=1 loops=1)
  6. Buffers: shared hit=27683 read=109487 written=79
  7. InitPlan 1 (returns $1)
  8. -> Finalize Aggregate (cost=97331.80..97331.81 rows=1 width=8) (actual time=527.776..527.858 rows=1 loops=1)
  9. Buffers: shared hit=129 read=44119
  10. -> Gather (cost=97331.58..97331.79 rows=2 width=8) (actual time=527.708..527.852 rows=3 loops=1)
  11. Workers Planned: 2
  12. Workers Launched: 2
  13. Buffers: shared hit=129 read=44119
  14. -> Partial Aggregate (cost=96331.58..96331.59 rows=1 width=8) (actual time=517.734..517.734 rows=1 loops=3)
  15. Buffers: shared hit=129 read=44119
  16. -> Parallel Seq Scan on test_1 (cost=0.00..85914.87 rows=4166687 width=0) (actual time=0.086..283.935 rows=3333333 loops=3)
  17. Buffers: shared hit=129 read=44119
  18. InitPlan 2 (returns $3)
  19. -> Finalize Aggregate (cost=49167.37..49167.38 rows=1 width=8) (actual time=245.154..245.196 rows=1 loops=1)
  20. Buffers: shared hit=11455 read=10670
  21. -> Gather (cost=49167.15..49167.36 rows=2 width=8) (actual time=245.086..245.190 rows=3 loops=1)
  22. Workers Planned: 2
  23. Workers Launched: 2
  24. Buffers: shared hit=11455 read=10670
  25. -> Partial Aggregate (cost=48167.15..48167.16 rows=1 width=8) (actual time=242.028..242.029 rows=1 loops=3)
  26. Buffers: shared hit=11455 read=10670
  27. -> Parallel Seq Scan on test_2 (cost=0.00..42958.72 rows=2083372 width=0) (actual time=0.019..130.565 rows=1666698 loops=3)
  28. Buffers: shared hit=11455 read=10670
  29. InitPlan 3 (returns $5)
  30. -> Finalize Aggregate (cost=10631.13..10631.14 rows=1 width=8) (actual time=51.357..51.389 rows=1 loops=1)
  31. Buffers: shared hit=4424
  32. -> Gather (cost=10630.92..10631.13 rows=2 width=8) (actual time=51.315..51.384 rows=3 loops=1)
  33. Workers Planned: 2
  34. Workers Launched: 2
  35. Buffers: shared hit=4424
  36. -> Partial Aggregate (cost=9630.92..9630.93 rows=1 width=8) (actual time=47.427..47.427 rows=1 loops=3)
  37. Buffers: shared hit=4424
  38. -> Parallel Seq Scan on test_3 (cost=0.00..8589.53 rows=416553 width=0) (actual time=0.006..25.158 rows=333243 loops=3)
  39. Buffers: shared hit=4424
  40. InitPlan 4 (returns $7)
  41. -> Finalize Aggregate (cost=49167.37..49167.38 rows=1 width=8) (actual time=245.959..246.003 rows=1 loops=1)
  42. Buffers: shared hit=11466 read=10659 written=4
  43. -> Gather (cost=49167.15..49167.36 rows=2 width=8) (actual time=245.890..245.998 rows=3 loops=1)
  44. Workers Planned: 2
  45. Workers Launched: 2
  46. Buffers: shared hit=11466 read=10659 written=4
  47. -> Partial Aggregate (cost=48167.15..48167.16 rows=1 width=8) (actual time=242.478..242.478 rows=1 loops=3)
  48. Buffers: shared hit=11466 read=10659 written=4
  49. -> Parallel Seq Scan on test_2 test_2_1 (cost=0.00..42958.72 rows=2083372 width=0) (actual time=0.065..130.902 rows=1666698 loops=3)
  50. Buffers: shared hit=11466 read=10659 written=4
  51. InitPlan 5 (returns $9)
  52. -> Finalize Aggregate (cost=97331.80..97331.81 rows=1 width=8) (actual time=502.641..504.263 rows=1 loops=1)
  53. Buffers: shared hit=209 read=44039 written=75
  54. -> Gather (cost=97331.58..97331.79 rows=2 width=8) (actual time=502.563..504.256 rows=3 loops=1)
  55. Workers Planned: 2
  56. Workers Launched: 2
  57. Buffers: shared hit=209 read=44039 written=75
  58. -> Partial Aggregate (cost=96331.58..96331.59 rows=1 width=8) (actual time=498.437..498.437 rows=1 loops=3)
  59. Buffers: shared hit=209 read=44039 written=75
  60. -> Parallel Seq Scan on test_1 test_1_1 (cost=0.00..85914.87 rows=4166687 width=0) (actual time=0.075..271.723 rows=3333333 loops=3)
  61. Buffers: shared hit=209 read=44039 written=75
  62. Planning:
  63. Buffers: shared hit=9
  64. Planning Time: 0.538 ms
  65. Execution Time: 1574.841 ms
  66. (61 rows)
  67.  
  68. Time: 1576.377 ms (00:01.576)
  69. test_2=#
  70.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement