explain.depesz.com

PostgreSQL's explain analyze made readable

Result: oYBu

Settings
# exclusive inclusive rows x rows loops node
1. 0.000 0.000 ↓ 0.0

Merge Right Join (cost=3,707,200,820.50..8,349,771,696.23 rows=22,291,819,142 width=4,112) (actual rows= loops=)

  • Merge Cond: (objectextensionfieldvalue14.objectid = "*SELECT* 1".id)
2. 0.000 0.000 ↓ 0.0

Index Scan using ixoefv_objectid on objectextensionfieldvalue objectextensionfieldvalue14 (cost=0.43..48,503.82 rows=224,891 width=30) (actual rows= loops=)

  • Filter: ('5b2ea0d7-326e-4095-a514-de82c998d7e9'::uuid = definitionid)
3. 0.000 0.000 ↓ 0.0

Materialize (cost=3,707,200,820.07..8,070,772,070.84 rows=22,170,691,116 width=2,341) (actual rows= loops=)

4. 0.000 0.000 ↓ 0.0

Merge Left Join (cost=3,707,200,820.07..8,015,345,343.05 rows=22,170,691,116 width=2,341) (actual rows= loops=)

  • Merge Cond: ("*SELECT* 1".id = objectextensionfieldvalue15.objectid)
5. 0.000 0.000 ↓ 0.0

Merge Left Join (cost=3,707,200,819.64..7,627,313,213.78 rows=22,169,303,484 width=2,327) (actual rows= loops=)

  • Merge Cond: ("*SELECT* 1".id = objectextensionfieldvalue19.objectid)
6. 0.000 0.000 ↓ 0.0

Merge Left Join (cost=3,707,166,152.75..7,552,622,709.47 rows=22,169,303,484 width=2,313) (actual rows= loops=)

  • Merge Cond: ("*SELECT* 1".id = objectextensionfieldvalue18.objectid)
7. 0.000 0.000 ↓ 0.0

Merge Left Join (cost=3,707,132,369.31..7,497,164,180.56 rows=22,169,303,484 width=2,299) (actual rows= loops=)

  • Merge Cond: ("*SELECT* 1".id = objectextensionfieldvalue17.objectid)
8. 0.000 0.000 ↓ 0.0

Merge Left Join (cost=3,707,132,368.88..7,111,112,400.31 rows=22,169,303,484 width=2,285) (actual rows= loops=)

  • Merge Cond: ("*SELECT* 1".id = objectextensionfieldvalue16.objectid)
9. 0.000 0.000 ↓ 0.0

Nested Loop Left Join (cost=3,707,132,368.46..6,724,036,250.33 rows=22,169,303,484 width=2,271) (actual rows= loops=)

10. 0.000 0.000 ↓ 0.0

Merge Left Join (cost=3,707,132,368.17..4,448,474,436.56 rows=3,346,389,501 width=2,247) (actual rows= loops=)

  • Merge Cond: ("*SELECT* 1".id = objectextensionfieldvalue13.objectid)
11. 0.000 0.000 ↓ 0.0

Nested Loop Left Join (cost=3,707,132,367.74..4,389,897,236.43 rows=3,333,141,519 width=2,233) (actual rows= loops=)

12. 0.000 0.000 ↓ 0.0

Nested Loop Left Join (cost=3,707,132,367.60..3,873,503,645.08 rows=3,333,141,519 width=1,717) (actual rows= loops=)

  • Join Filter: ("*SELECT* 1".breaktypeid = breaktype7.id)
13. 0.000 0.000 ↓ 0.0

Merge Left Join (cost=3,707,132,367.60..3,773,676,055.56 rows=3,333,141,519 width=1,481) (actual rows= loops=)

  • Merge Cond: ("*SELECT* 1".id = objectextensionfieldvalue12.objectid)
14. 0.000 0.000 ↓ 0.0

Sort (cost=3,707,078,761.26..3,715,411,615.06 rows=3,333,141,519 width=1,467) (actual rows= loops=)

  • Sort Key: "*SELECT* 1".id
15. 0.000 0.000 ↓ 0.0

Hash Left Join (cost=96,145,944.97..745,116,123.64 rows=3,333,141,519 width=1,467) (actual rows= loops=)

  • Hash Cond: ("*SELECT* 1".clientid = clients10.id)
16. 0.000 0.000 ↓ 0.0

Hash Left Join (cost=96,145,942.79..736,181,218.97 rows=3,333,141,519 width=1,333) (actual rows= loops=)

  • Hash Cond: (projectclient2.clientid = clients9.id)
17. 0.000 0.000 ↓ 0.0

Hash Left Join (cost=96,145,940.61..723,311,587.04 rows=3,333,141,519 width=1,199) (actual rows= loops=)

  • Hash Cond: ("*SELECT* 1".billingrateid = billingrate6.id)
18. 0.000 0.000 ↓ 0.0

Hash Left Join (cost=96,145,939.56..714,376,683.50 rows=3,333,141,519 width=1,081) (actual rows= loops=)

  • Hash Cond: ("*SELECT* 1".taskid = task5.id)
19. 0.000 0.000 ↓ 0.0

Hash Left Join (cost=96,145,937.98..705,441,779.43 rows=3,333,141,519 width=447) (actual rows= loops=)

  • Hash Cond: ("*SELECT* 1".activityid = activities3.id)
20. 0.000 0.000 ↓ 0.0

Merge Join (cost=96,145,936.86..696,506,875.83 rows=3,333,141,519 width=211) (actual rows= loops=)

  • Merge Cond: (allstartenddates.userid = "*SELECT* 1".userid)
  • Join Filter: (("*SELECT* 1".entrydate >= allstartenddates.startdate) AND ("*SELECT* 1".entrydate <= ((allstartenddates.nextstartdate - '1 day'::interval))))
21. 0.000 0.000 ↓ 0.0

Sort (cost=11,179.08..11,273.95 rows=37,946 width=36) (actual rows= loops=)

  • Sort Key: allstartenddates.userid
22. 0.000 0.000 ↓ 0.0

CTE Scan on allstartenddates (cost=6,292.21..7,913.51 rows=37,946 width=36) (actual rows= loops=)

  • Filter: ((nextstartdate IS NOT NULL) AND (userid <> $2))
23.          

CTE alldates

24. 0.000 0.000 ↓ 0.0

HashAggregate (cost=1,456.87..1,840.15 rows=38,328 width=12) (actual rows= loops=)

  • Group Key: userhierarchy.userid, userhierarchy.startdate
25. 0.000 0.000 ↓ 0.0

Append (cost=0.00..1,265.23 rows=38,328 width=12) (actual rows= loops=)

26. 0.000 0.000 ↓ 0.0

Seq Scan on userhierarchy (cost=0.00..16.96 rows=896 width=12) (actual rows= loops=)

27. 0.000 0.000 ↓ 0.0

Seq Scan on userhierarchy userhierarchy_1 (cost=0.00..19.20 rows=896 width=12) (actual rows= loops=)

28. 0.000 0.000 ↓ 0.0

Subquery Scan on *SELECT* 3_1 (cost=0.28..43.99 rows=1,117 width=12) (actual rows= loops=)

29. 0.000 0.000 ↓ 0.0

Index Only Scan using ix4ul_userlocationstartend on userlocation (cost=0.28..30.03 rows=1,117 width=8) (actual rows= loops=)

30. 0.000 0.000 ↓ 0.0

Index Only Scan using ix4ul_userlocationstartend on userlocation userlocation_1 (cost=0.28..32.83 rows=1,117 width=12) (actual rows= loops=)

31. 0.000 0.000 ↓ 0.0

Subquery Scan on *SELECT* 5 (cost=0.00..35.43 rows=1,130 width=12) (actual rows= loops=)

32. 0.000 0.000 ↓ 0.0

Seq Scan on userdivision (cost=0.00..21.30 rows=1,130 width=8) (actual rows= loops=)

33. 0.000 0.000 ↓ 0.0

Seq Scan on userdivision userdivision_1 (cost=0.00..24.12 rows=1,130 width=12) (actual rows= loops=)

34. 0.000 0.000 ↓ 0.0

Subquery Scan on *SELECT* 7 (cost=0.00..35.43 rows=1,130 width=12) (actual rows= loops=)

35. 0.000 0.000 ↓ 0.0

Seq Scan on usercostcenter (cost=0.00..21.30 rows=1,130 width=8) (actual rows= loops=)

36. 0.000 0.000 ↓ 0.0

Seq Scan on usercostcenter usercostcenter_1 (cost=0.00..24.12 rows=1,130 width=12) (actual rows= loops=)

37. 0.000 0.000 ↓ 0.0

Subquery Scan on *SELECT* 9 (cost=0.00..35.43 rows=1,130 width=12) (actual rows= loops=)

38. 0.000 0.000 ↓ 0.0

Seq Scan on userservicecenter (cost=0.00..21.30 rows=1,130 width=8) (actual rows= loops=)

39. 0.000 0.000 ↓ 0.0

Seq Scan on userservicecenter userservicecenter_1 (cost=0.00..24.12 rows=1,130 width=12) (actual rows= loops=)

40. 0.000 0.000 ↓ 0.0

Subquery Scan on *SELECT* 11 (cost=0.00..35.43 rows=1,130 width=12) (actual rows= loops=)

41. 0.000 0.000 ↓ 0.0

Seq Scan on userdepartmentgroup (cost=0.00..21.30 rows=1,130 width=8) (actual rows= loops=)

42. 0.000 0.000 ↓ 0.0

Seq Scan on userdepartmentgroup userdepartmentgroup_1 (cost=0.00..24.12 rows=1,130 width=12) (actual rows= loops=)

43. 0.000 0.000 ↓ 0.0

Subquery Scan on *SELECT* 13 (cost=0.00..35.43 rows=1,130 width=12) (actual rows= loops=)

44. 0.000 0.000 ↓ 0.0

Seq Scan on useremployeetypegroup (cost=0.00..21.30 rows=1,130 width=8) (actual rows= loops=)

45. 0.000 0.000 ↓ 0.0

Seq Scan on useremployeetypegroup useremployeetypegroup_1 (cost=0.00..24.12 rows=1,130 width=12) (actual rows= loops=)

46. 0.000 0.000 ↓ 0.0

Subquery Scan on *SELECT* 15 (cost=0.00..169.34 rows=5,304 width=12) (actual rows= loops=)

47. 0.000 0.000 ↓ 0.0

Seq Scan on userprojectroleratehistory (cost=0.00..103.04 rows=5,304 width=8) (actual rows= loops=)

48. 0.000 0.000 ↓ 0.0

Seq Scan on userprojectroleratehistory userprojectroleratehistory_1 (cost=0.00..116.30 rows=5,304 width=12) (actual rows= loops=)

49. 0.000 0.000 ↓ 0.0

Subquery Scan on *SELECT* 17 (cost=0.00..161.98 rows=5,288 width=12) (actual rows= loops=)

50. 0.000 0.000 ↓ 0.0

Seq Scan on userpayrollratehistory (cost=0.00..95.88 rows=5,288 width=8) (actual rows= loops=)

51. 0.000 0.000 ↓ 0.0

Seq Scan on userpayrollratehistory userpayrollratehistory_1 (cost=0.00..109.10 rows=5,288 width=12) (actual rows= loops=)

52. 0.000 0.000 ↓ 0.0

Subquery Scan on *SELECT* 19 (cost=0.28..54.27 rows=909 width=12) (actual rows= loops=)

53. 0.000 0.000 ↓ 0.0

Index Only Scan using userinfo_pkey on userinfo (cost=0.28..42.91 rows=909 width=8) (actual rows= loops=)

54. 0.000 0.000 ↓ 0.0

Index Only Scan using userinfo_pkey on userinfo userinfo_1 (cost=0.28..42.91 rows=909 width=12) (actual rows= loops=)

55.          

CTE allstartenddates

56. 0.000 0.000 ↓ 0.0

WindowAgg (cost=3,684.49..4,451.05 rows=38,328 width=20) (actual rows= loops=)

57. 0.000 0.000 ↓ 0.0

Sort (cost=3,684.49..3,780.31 rows=38,328 width=12) (actual rows= loops=)

  • Sort Key: main.userid, main.startdate
58. 0.000 0.000 ↓ 0.0

CTE Scan on alldates main (cost=0.00..766.56 rows=38,328 width=12) (actual rows= loops=)

59.          

Initplan (for CTE Scan)

60. 0.000 0.000 ↓ 0.0

Seq Scan on systeminformation (cost=0.00..1.01 rows=1 width=4) (actual rows= loops=)

61. 0.000 0.000 ↓ 0.0

Materialize (cost=96,134,757.78..96,925,309.45 rows=158,110,334 width=195) (actual rows= loops=)

62. 0.000 0.000 ↓ 0.0

Sort (cost=96,134,757.78..96,530,033.62 rows=158,110,334 width=195) (actual rows= loops=)

  • Sort Key: "*SELECT* 1".userid
63. 0.000 0.000 ↓ 0.0

Hash Left Join (cost=242,540.49..65,956,350.73 rows=158,110,334 width=195) (actual rows= loops=)

  • Hash Cond: ("*SELECT* 1".projectid = project4.id)
64. 0.000 0.000 ↓ 0.0

Hash Left Join (cost=242,530.31..65,532,506.02 rows=158,110,334 width=167) (actual rows= loops=)

  • Hash Cond: ("*SELECT* 1".projectid = projectclient2.projectid)
65. 0.000 0.000 ↓ 0.0

Append (cost=242,516.74..64,267,609.78 rows=158,110,334 width=158) (actual rows= loops=)

66. 0.000 0.000 ↓ 0.0

Subquery Scan on *SELECT* 1 (cost=242,516.74..64,263,843.97 rows=158,065,700 width=158) (actual rows= loops=)

67. 0.000 0.000 ↓ 0.0

Hash Left Join (cost=242,516.74..62,683,186.97 rows=158,065,700 width=174) (actual rows= loops=)

  • Hash Cond: (te.id = te_isbillable.timeentryid)
68. 0.000 0.000 ↓ 0.0

Hash Left Join (cost=220,846.54..17,415,203.65 rows=158,065,700 width=300) (actual rows= loops=)

  • Hash Cond: (("substring"(te_client.uri, concat('^urn:replicon-tenant:', si.tenantslug, ':client:(.*)$')))::integer = client.id)
69. 0.000 0.000 ↓ 0.0

Hash Left Join (cost=220,844.36..16,908,897.28 rows=158,065,700 width=358) (actual rows= loops=)

  • Hash Cond: (te.id = te_client.timeentryid)
70. 0.000 0.000 ↓ 0.0

Hash Left Join (cost=199,174.15..16,294,474.20 rows=158,065,700 width=296) (actual rows= loops=)

  • Hash Cond: (("substring"(te_timeofftype.uri, concat('urn:replicon-tenant:', si.tenantslug, ':time-off-type:(.*)$')))::integer = toc.id)
71. 0.000 0.000 ↓ 0.0

Hash Left Join (cost=199,172.75..15,788,168.61 rows=158,065,700 width=354) (actual rows= loops=)

  • Hash Cond: (te.id = te_timeofftype.timeentryid)
72. 0.000 0.000 ↓ 0.0

Hash Left Join (cost=177,502.55..15,173,745.53 rows=158,065,700 width=292) (actual rows= loops=)

  • Hash Cond: (("substring"(te_breaktype.uri, concat('^urn:replicon-tenant:', si.tenantslug, ':break-type:(.*)$')))::uuid = bt.id)
73. 0.000 0.000 ↓ 0.0

Hash Left Join (cost=177,501.50..14,667,440.30 rows=158,065,700 width=338) (actual rows= loops=)

  • Hash Cond: (te.id = te_breaktype.timeentryid)
74. 0.000 0.000 ↓ 0.0

Hash Left Join (cost=155,831.30..14,053,017.22 rows=158,065,700 width=276) (actual rows= loops=)

  • Hash Cond: (te.id = te_billingrate.timeentryid)
75. 0.000 0.000 ↓ 0.0

Hash Left Join (cost=120,704.93..8,613,937.10 rows=158,065,700 width=214) (actual rows= loops=)

  • Hash Cond: (task.projectid = taskproj.id)
76. 0.000 0.000 ↓ 0.0

Hash Left Join (cost=120,694.74..8,180,875.79 rows=158,065,700 width=206) (actual rows= loops=)

  • Hash Cond: (("substring"(te_task.uri, concat('^urn:replicon-tenant:', si.tenantslug, ':task:(.*)$')))::integer = task.id)
77. 0.000 0.000 ↓ 0.0

Hash Left Join (cost=120,693.16..7,674,570.01 rows=158,065,700 width=260) (actual rows= loops=)

  • Hash Cond: (te.id = te_task.timeentryid)
78. 0.000 0.000 ↓ 0.0

Hash Left Join (cost=88,343.77..2,414,312.87 rows=158,065,700 width=198) (actual rows= loops=)

  • Hash Cond: (("substring"(te_project.uri, concat('^urn:replicon-tenant:', si.tenantslug, ':project:(.*)$')))::integer = proj.id)
79. 0.000 0.000 ↓ 0.0

Hash Join (cost=88,333.59..1,907,998.50 rows=158,065,700 width=248) (actual rows= loops=)

  • Hash Cond: (te.userid = ui.id)
80. 0.000 0.000 ↓ 0.0

Hash Left Join (cost=73,491.12..114,308.97 rows=243,178 width=199) (actual rows= loops=)

  • Hash Cond: (("substring"(te_activity.uri, concat('^urn:replicon-tenant:', si.tenantslug, ':activity:(.*)$')))::integer = act.id)
81. 0.000 0.000 ↓ 0.0

Nested Loop (cost=73,490.01..113,528.93 rows=243,178 width=257) (actual rows= loops=)

82. 0.000 0.000 ↓ 0.0

Seq Scan on systeminformation si (cost=0.00..1.01 rows=1 width=33) (actual rows= loops=)

83. 0.000 0.000 ↓ 0.0

Hash Right Join (cost=73,490.01..111,096.14 rows=243,178 width=224) (actual rows= loops=)

  • Hash Cond: (te_project.timeentryid = te.id)
84. 0.000 0.000 ↓ 0.0

Seq Scan on timeentrymetadata te_project (cost=0.00..34,613.26 rows=217,663 width=78) (actual rows= loops=)

  • Filter: (upper(key) = 'URN:REPLICON:TIME-ENTRY-METADATA-KEY:PROJECT'::text)
85. 0.000 0.000 ↓ 0.0

Hash (cost=70,450.28..70,450.28 rows=243,178 width=162) (actual rows= loops=)

86. 0.000 0.000 ↓ 0.0

Hash Right Join (cost=48,071.91..70,450.28 rows=243,178 width=162) (actual rows= loops=)

  • Hash Cond: (te_comment.timeentryid = te.id)
87. 0.000 0.000 ↓ 0.0

Index Scan using ixtem2timeentryid on timeentrymetadata te_comment (cost=0.55..22,369.23 rows=705 width=56) (actual rows= loops=)

  • Index Cond: (upper(key) = 'URN:REPLICON:TIME-ENTRY-METADATA-KEY:COMMENTS'::text)
88. 0.000 0.000 ↓ 0.0

Hash (cost=45,031.64..45,031.64 rows=243,178 width=122) (actual rows= loops=)

89. 0.000 0.000 ↓ 0.0

Hash Right Join (cost=9,821.45..45,031.64 rows=243,178 width=122) (actual rows= loops=)

  • Hash Cond: (te_activity.timeentryid = te.id)
90. 0.000 0.000 ↓ 0.0

Seq Scan on timeentrymetadata te_activity (cost=0.00..34,613.26 rows=227,396 width=78) (actual rows= loops=)

  • Filter: (upper(key) = 'URN:REPLICON:TIME-ENTRY-METADATA-KEY:ACTIVITY'::text)
91. 0.000 0.000 ↓ 0.0

Hash (cost=6,781.73..6,781.73 rows=243,178 width=60) (actual rows= loops=)

92. 0.000 0.000 ↓ 0.0

Seq Scan on timeentry te (cost=0.00..6,781.73 rows=243,178 width=60) (actual rows= loops=)

  • Filter: ((timeallocationtype <> 2) OR (timeallocationtype IS NULL))
93. 0.000 0.000 ↓ 0.0

Hash (cost=1.05..1.05 rows=5 width=4) (actual rows= loops=)

94. 0.000 0.000 ↓ 0.0

Seq Scan on activities act (cost=0.00..1.05 rows=5 width=4) (actual rows= loops=)

95. 0.000 0.000 ↓ 0.0

Hash (cost=7,456.84..7,456.84 rows=590,850 width=53) (actual rows= loops=)

96. 0.000 0.000 ↓ 0.0

Nested Loop (cost=0.00..7,456.84 rows=590,850 width=53) (actual rows= loops=)

97. 0.000 0.000 ↓ 0.0

Seq Scan on userinfo ui (cost=0.00..53.09 rows=909 width=21) (actual rows= loops=)

98. 0.000 0.000 ↓ 0.0

Materialize (cost=0.00..19.75 rows=650 width=32) (actual rows= loops=)

99. 0.000 0.000 ↓ 0.0

Seq Scan on projectsysteminformation psi (cost=0.00..16.50 rows=650 width=32) (actual rows= loops=)

100. 0.000 0.000 ↓ 0.0

Hash (cost=8.97..8.97 rows=97 width=12) (actual rows= loops=)

101. 0.000 0.000 ↓ 0.0

Seq Scan on project proj (cost=0.00..8.97 rows=97 width=12) (actual rows= loops=)

102. 0.000 0.000 ↓ 0.0

Hash (cost=32,174.83..32,174.83 rows=13,965 width=78) (actual rows= loops=)

103. 0.000 0.000 ↓ 0.0

Index Scan using ixtem2timeentryid on timeentrymetadata te_task (cost=0.55..32,174.83 rows=13,965 width=78) (actual rows= loops=)

  • Index Cond: (upper(key) = 'URN:REPLICON:TIME-ENTRY-METADATA-KEY:TASK'::text)
104. 0.000 0.000 ↓ 0.0

Hash (cost=1.26..1.26 rows=26 width=8) (actual rows= loops=)

105. 0.000 0.000 ↓ 0.0

Seq Scan on task (cost=0.00..1.26 rows=26 width=8) (actual rows= loops=)

106. 0.000 0.000 ↓ 0.0

Hash (cost=8.97..8.97 rows=97 width=12) (actual rows= loops=)

107. 0.000 0.000 ↓ 0.0

Seq Scan on project taskproj (cost=0.00..8.97 rows=97 width=12) (actual rows= loops=)

108. 0.000 0.000 ↓ 0.0

Hash (cost=34,613.26..34,613.26 rows=41,049 width=78) (actual rows= loops=)

109. 0.000 0.000 ↓ 0.0

Seq Scan on timeentrymetadata te_billingrate (cost=0.00..34,613.26 rows=41,049 width=78) (actual rows= loops=)

  • Filter: (upper(key) = 'URN:REPLICON:TIME-ENTRY-METADATA-KEY:BILLING-RATE'::text)
110. 0.000 0.000 ↓ 0.0

Hash (cost=21,670.19..21,670.19 rows=1 width=78) (actual rows= loops=)

111. 0.000 0.000 ↓ 0.0

Index Scan using ixtem2timeentryid on timeentrymetadata te_breaktype (cost=0.55..21,670.19 rows=1 width=78) (actual rows= loops=)

  • Index Cond: (upper(key) = 'URN:REPLICON:TIME-ENTRY-METADATA-KEY:BREAK-TYPE'::text)
112. 0.000 0.000 ↓ 0.0

Hash (cost=1.02..1.02 rows=2 width=16) (actual rows= loops=)

113. 0.000 0.000 ↓ 0.0

Seq Scan on breaktype bt (cost=0.00..1.02 rows=2 width=16) (actual rows= loops=)

114. 0.000 0.000 ↓ 0.0

Hash (cost=21,670.19..21,670.19 rows=1 width=78) (actual rows= loops=)

115. 0.000 0.000 ↓ 0.0

Index Scan using ixtem2timeentryid on timeentrymetadata te_timeofftype (cost=0.55..21,670.19 rows=1 width=78) (actual rows= loops=)

  • Index Cond: (upper(key) = 'URN:REPLICON:TIME-ENTRY-METADATA-KEY:TIME-OFF-TYPE'::text)
116. 0.000 0.000 ↓ 0.0

Hash (cost=1.18..1.18 rows=18 width=4) (actual rows= loops=)

117. 0.000 0.000 ↓ 0.0

Seq Scan on timeoffcode toc (cost=0.00..1.18 rows=18 width=4) (actual rows= loops=)

118. 0.000 0.000 ↓ 0.0

Hash (cost=21,670.19..21,670.19 rows=1 width=78) (actual rows= loops=)

119. 0.000 0.000 ↓ 0.0

Index Scan using ixtem2timeentryid on timeentrymetadata te_client (cost=0.55..21,670.19 rows=1 width=78) (actual rows= loops=)

  • Index Cond: (upper(key) = 'URN:REPLICON:TIME-ENTRY-METADATA-KEY:CLIENT'::text)
120. 0.000 0.000 ↓ 0.0

Hash (cost=2.08..2.08 rows=8 width=4) (actual rows= loops=)

121. 0.000 0.000 ↓ 0.0

Seq Scan on clients client (cost=0.00..2.08 rows=8 width=4) (actual rows= loops=)

122. 0.000 0.000 ↓ 0.0

Hash (cost=21,670.19..21,670.19 rows=1 width=17) (actual rows= loops=)

123. 0.000 0.000 ↓ 0.0

Index Scan using ixtem2timeentryid on timeentrymetadata te_isbillable (cost=0.55..21,670.19 rows=1 width=17) (actual rows= loops=)

  • Index Cond: (upper(key) = 'URN:REPLICON:TIME-ENTRY-METADATA-KEY:IS-BILLABLE'::text)
124. 0.000 0.000 ↓ 0.0

Subquery Scan on *SELECT* 2 (cost=0.54..6.65 rows=1 width=150) (actual rows= loops=)

125. 0.000 0.000 ↓ 0.0

Nested Loop Left Join (cost=0.54..6.64 rows=1 width=166) (actual rows= loops=)

126. 0.000 0.000 ↓ 0.0

Nested Loop (cost=0.40..4.44 rows=1 width=133) (actual rows= loops=)

127. 0.000 0.000 ↓ 0.0

Index Scan using ixallocatedtimerootid on allocatedtime at (cost=0.12..2.14 rows=1 width=116) (actual rows= loops=)

128. 0.000 0.000 ↓ 0.0

Index Scan using userinfo_pkey on userinfo ui_1 (cost=0.28..2.29 rows=1 width=21) (actual rows= loops=)

  • Index Cond: (id = at.userid)
129. 0.000 0.000 ↓ 0.0

Index Scan using project_pkey on project pj (cost=0.14..2.16 rows=1 width=8) (actual rows= loops=)

  • Index Cond: (at.projectid = id)
130. 0.000 0.000 ↓ 0.0

Subquery Scan on *SELECT* 3 (cost=1,833.20..3,620.29 rows=43,823 width=179) (actual rows= loops=)

131. 0.000 0.000 ↓ 0.0

Hash Join (cost=1,833.20..3,182.06 rows=43,823 width=195) (actual rows= loops=)

  • Hash Cond: (toff.userid = ui_2.id)
132. 0.000 0.000 ↓ 0.0

Hash Join (cost=1,768.75..3,002.04 rows=43,823 width=105) (actual rows= loops=)

  • Hash Cond: (toe.timeoffid = toff.id)
133. 0.000 0.000 ↓ 0.0

Seq Scan on timeoffentries toe (cost=0.00..1,118.23 rows=43,823 width=40) (actual rows= loops=)

134. 0.000 0.000 ↓ 0.0

Hash (cost=1,408.89..1,408.89 rows=28,789 width=73) (actual rows= loops=)

135. 0.000 0.000 ↓ 0.0

Seq Scan on timeoffs toff (cost=0.00..1,408.89 rows=28,789 width=73) (actual rows= loops=)

136. 0.000 0.000 ↓ 0.0

Hash (cost=53.09..53.09 rows=909 width=21) (actual rows= loops=)

137. 0.000 0.000 ↓ 0.0

Seq Scan on userinfo ui_2 (cost=0.00..53.09 rows=909 width=21) (actual rows= loops=)

138. 0.000 0.000 ↓ 0.0

Subquery Scan on *SELECT* 4 (cost=100.04..138.87 rows=810 width=150) (actual rows= loops=)

139. 0.000 0.000 ↓ 0.0

Hash Left Join (cost=100.04..130.77 rows=810 width=166) (actual rows= loops=)

  • Hash Cond: (COALESCE(tp_start.projectid, tp_end.projectid) = proj_1.id)
140. 0.000 0.000 ↓ 0.0

Hash Join (cost=89.85..114.36 rows=810 width=149) (actual rows= loops=)

  • Hash Cond: (punch_pair.endtimepunchid = tp_end.id)
141. 0.000 0.000 ↓ 0.0

Hash Join (cost=77.15..99.53 rows=810 width=109) (actual rows= loops=)

  • Hash Cond: (punch_pair.starttimepunchid = tp_start.id)
142. 0.000 0.000 ↓ 0.0

Hash Join (cost=64.45..84.69 rows=810 width=69) (actual rows= loops=)

  • Hash Cond: (punch_pair.userid = ui_3.id)
143. 0.000 0.000 ↓ 0.0

Seq Scan on denormalizedtimepunchpair punch_pair (cost=0.00..18.10 rows=810 width=52) (actual rows= loops=)

144. 0.000 0.000 ↓ 0.0

Hash (cost=53.09..53.09 rows=909 width=21) (actual rows= loops=)

145. 0.000 0.000 ↓ 0.0

Seq Scan on userinfo ui_3 (cost=0.00..53.09 rows=909 width=21) (actual rows= loops=)

146. 0.000 0.000 ↓ 0.0

Hash (cost=11.20..11.20 rows=120 width=72) (actual rows= loops=)

147. 0.000 0.000 ↓ 0.0

Seq Scan on timepunch tp_start (cost=0.00..11.20 rows=120 width=72) (actual rows= loops=)

148. 0.000 0.000 ↓ 0.0

Hash (cost=11.20..11.20 rows=120 width=72) (actual rows= loops=)

149. 0.000 0.000 ↓ 0.0

Seq Scan on timepunch tp_end (cost=0.00..11.20 rows=120 width=72) (actual rows= loops=)

150. 0.000 0.000 ↓ 0.0

Hash (cost=8.97..8.97 rows=97 width=8) (actual rows= loops=)

151. 0.000 0.000 ↓ 0.0

Seq Scan on project proj_1 (cost=0.00..8.97 rows=97 width=8) (actual rows= loops=)

152. 0.000 0.000 ↓ 0.0

Hash (cost=12.51..12.51 rows=85 width=13) (actual rows= loops=)

153. 0.000 0.000 ↓ 0.0

Hash Join (cost=10.43..12.51 rows=85 width=13) (actual rows= loops=)

  • Hash Cond: (projectclient2.projectid = project20.id)
154. 0.000 0.000 ↓ 0.0

Seq Scan on projectclient projectclient2 (cost=0.00..1.85 rows=85 width=13) (actual rows= loops=)

155. 0.000 0.000 ↓ 0.0

Hash (cost=9.21..9.21 rows=97 width=4) (actual rows= loops=)

156. 0.000 0.000 ↓ 0.0

Seq Scan on project project20 (cost=0.00..9.21 rows=97 width=4) (actual rows= loops=)

  • Filter: (clientbillingallocationmethod = 0)
157. 0.000 0.000 ↓ 0.0

Hash (cost=8.97..8.97 rows=97 width=32) (actual rows= loops=)

158. 0.000 0.000 ↓ 0.0

Seq Scan on project project4 (cost=0.00..8.97 rows=97 width=32) (actual rows= loops=)

159. 0.000 0.000 ↓ 0.0

Hash (cost=1.05..1.05 rows=5 width=240) (actual rows= loops=)

160. 0.000 0.000 ↓ 0.0

Seq Scan on activities activities3 (cost=0.00..1.05 rows=5 width=240) (actual rows= loops=)

161. 0.000 0.000 ↓ 0.0

Hash (cost=1.26..1.26 rows=26 width=638) (actual rows= loops=)

162. 0.000 0.000 ↓ 0.0

Seq Scan on task task5 (cost=0.00..1.26 rows=26 width=638) (actual rows= loops=)

163. 0.000 0.000 ↓ 0.0

Hash (cost=1.02..1.02 rows=2 width=134) (actual rows= loops=)

164. 0.000 0.000 ↓ 0.0

Seq Scan on billingrate billingrate6 (cost=0.00..1.02 rows=2 width=134) (actual rows= loops=)

165. 0.000 0.000 ↓ 0.0

Hash (cost=2.08..2.08 rows=8 width=138) (actual rows= loops=)

166. 0.000 0.000 ↓ 0.0

Seq Scan on clients clients9 (cost=0.00..2.08 rows=8 width=138) (actual rows= loops=)

167. 0.000 0.000 ↓ 0.0

Hash (cost=2.08..2.08 rows=8 width=138) (actual rows= loops=)

168. 0.000 0.000 ↓ 0.0

Seq Scan on clients clients10 (cost=0.00..2.08 rows=8 width=138) (actual rows= loops=)

169. 0.000 0.000 ↓ 0.0

Sort (cost=53,606.34..54,164.18 rows=223,136 width=30) (actual rows= loops=)

  • Sort Key: objectextensionfieldvalue12.objectid
170. 0.000 0.000 ↓ 0.0

Seq Scan on objectextensionfieldvalue objectextensionfieldvalue12 (cost=0.00..33,783.43 rows=223,136 width=30) (actual rows= loops=)

  • Filter: ('2b4389cf-92f8-4c68-8544-03d97babeb51'::uuid = definitionid)
171. 0.000 0.000 ↓ 0.0

Materialize (cost=0.00..1.03 rows=2 width=252) (actual rows= loops=)

172. 0.000 0.000 ↓ 0.0

Seq Scan on breaktype breaktype7 (cost=0.00..1.02 rows=2 width=252) (actual rows= loops=)

173. 0.000 0.000 ↓ 0.0

Index Scan using timeoffcode_pkey on timeoffcode timeoffcode8 (cost=0.14..0.16 rows=1 width=520) (actual rows= loops=)

  • Index Cond: ("*SELECT* 1".timeofftypeid = id)
174. 0.000 0.000 ↓ 0.0

Materialize (cost=0.43..49,065.22 rows=224,558 width=30) (actual rows= loops=)

175. 0.000 0.000 ↓ 0.0

Index Scan using ixoefv_objectid on objectextensionfieldvalue objectextensionfieldvalue13 (cost=0.43..48,503.82 rows=224,558 width=30) (actual rows= loops=)

  • Filter: ('77c576b0-116c-4dbc-bc6c-203650f21060'::uuid = definitionid)
176. 0.000 0.000 ↓ 0.0

Index Scan using ixtsuseridstartdateenddate on timesheet timesheet11 (cost=0.29..0.61 rows=7 width=28) (actual rows= loops=)

  • Index Cond: (("*SELECT* 1".userid = userid) AND ("*SELECT* 1".entrydate >= startdate) AND ("*SELECT* 1".entrydate <= enddate))
177. 0.000 0.000 ↓ 0.0

Materialize (cost=0.43..49,061.42 rows=223,040 width=30) (actual rows= loops=)

178. 0.000 0.000 ↓ 0.0

Index Scan using ixoefv_objectid on objectextensionfieldvalue objectextensionfieldvalue16 (cost=0.43..48,503.82 rows=223,040 width=30) (actual rows= loops=)

  • Filter: ('257b06ee-1ac2-4856-9f79-f73c9a0bb250'::uuid = definitionid)
179. 0.000 0.000 ↓ 0.0

Materialize (cost=0.43..49,059.70 rows=222,351 width=30) (actual rows= loops=)

180. 0.000 0.000 ↓ 0.0

Index Scan using ixoefv_objectid on objectextensionfieldvalue objectextensionfieldvalue17 (cost=0.43..48,503.82 rows=222,351 width=30) (actual rows= loops=)

  • Filter: ('a90093ce-7526-42b3-8230-e21f4f7cdb60'::uuid = definitionid)
181. 0.000 0.000 ↓ 0.0

Materialize (cost=33,783.44..33,783.44 rows=1 width=30) (actual rows= loops=)

182. 0.000 0.000 ↓ 0.0

Sort (cost=33,783.44..33,783.44 rows=1 width=30) (actual rows= loops=)

  • Sort Key: objectextensionfieldvalue18.objectid
183. 0.000 0.000 ↓ 0.0

Seq Scan on objectextensionfieldvalue objectextensionfieldvalue18 (cost=0.00..33,783.43 rows=1 width=30) (actual rows= loops=)

  • Filter: ('ecabe59c-ee12-49c5-827b-ae66c4e33995'::uuid = definitionid)
184. 0.000 0.000 ↓ 0.0

Sort (cost=34,666.90..34,699.24 rows=12,936 width=30) (actual rows= loops=)

  • Sort Key: objectextensionfieldvalue19.objectid
185. 0.000 0.000 ↓ 0.0

Seq Scan on objectextensionfieldvalue objectextensionfieldvalue19 (cost=0.00..33,783.43 rows=12,936 width=30) (actual rows= loops=)

  • Filter: ('ced5329b-a8d9-4f41-9ffa-2b37c6493788'::uuid = definitionid)
186. 0.000 0.000 ↓ 0.0

Materialize (cost=0.43..49,063.03 rows=223,683 width=30) (actual rows= loops=)

187. 0.000 0.000 ↓ 0.0

Index Scan using ixoefv_objectid on objectextensionfieldvalue objectextensionfieldvalue15 (cost=0.43..48,503.82 rows=223,683 width=30) (actual rows= loops=)

  • Filter: ('8f40b27f-b60d-43f8-a756-01ba5362d667'::uuid = definitionid)