explain.depesz.com

PostgreSQL's explain analyze made readable

Result: ZYZw : DominosPizza

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

Sort (cost=895,721.82..895,721.82 rows=1 width=3,019) (actual rows= loops=)

  • Sort Key: ((program.name)::character varying(255)) COLLATE "en_US", ((pj.name)::character varying(255)) COLLATE "en_US", ((employeetype9.name)::character varying(50)) COLLATE "en_US", ((tk.name)::character varying(255)) COLLATE "en_US", ((ui.lastname)::character varying(50)) COLLATE "en_US", ((ui.firstname)::character varying(50)) COLLATE "en_US", imeexpensecostbilling2_facts12.userduplicatename2, ((login.loginname)::character varying(255)) COLLATE "en_US", ((ui.displayname)::text) COLLATE "en_US", ((ui.externalid)::character varying(255)) COLLATE "en_US", imeexpensecostbilling2_facts12.timesheetstartdate3, imeexpensecostbilling2_facts12.timesheetenddate4, ta.timestamputc
2.          

CTE eexpensecostbilling2_facts0cte

3. 0.000 0.000 ↓ 0.0

GroupAggregate (cost=895,708.68..895,708.72 rows=1 width=61) (actual rows= loops=)

  • Group Key: at.userid, ui_1.duplicatename, ts_2.startdate, ts_2.enddate, "*SELECT* 1".expensestatus, tslist_1.timesheetstatus, at.projectid, at.taskid, ts_3.id
4. 0.000 0.000 ↓ 0.0

Sort (cost=895,708.68..895,708.69 rows=1 width=61) (actual rows= loops=)

  • Sort Key: at.userid, ui_1.duplicatename, ts_2.startdate, ts_2.enddate, "*SELECT* 1".expensestatus, tslist_1.timesheetstatus, at.projectid, at.taskid, ts_3.id
5. 0.000 0.000 ↓ 0.0

Nested Loop (cost=15,279.32..895,708.67 rows=1 width=61) (actual rows= loops=)

  • Join Filter: (ts_3.id = timesheet6.id)
6. 0.000 0.000 ↓ 0.0

Index Scan using uix2tsuseridstartdate on timesheet timesheet6 (cost=0.29..1,172.26 rows=1 width=16) (actual rows= loops=)

  • Index Cond: ((startdate >= '2020-07-13'::date) AND (startdate <= '2020-08-09'::date))
  • Filter: ((enddate >= '2020-07-13'::date) AND (enddate <= '2020-08-09'::date))
7. 0.000 0.000 ↓ 0.0

Hash Left Join (cost=15,279.03..893,976.44 rows=44,798 width=61) (actual rows= loops=)

  • Hash Cond: (at.userid = ui_1.id)
8. 0.000 0.000 ↓ 0.0

Hash Left Join (cost=15,191.22..893,770.77 rows=44,798 width=60) (actual rows= loops=)

  • Hash Cond: ((NULL::integer) = "*SELECT* 1".expenseid)
  • Filter: ((tslist_1.timesheetstatus = ANY ('{0,1,2,3,4}'::integer[])) OR ("*SELECT* 1".expensestatus = ANY ('{0,1,2,3,4}'::integer[])))
9. 0.000 0.000 ↓ 0.0

Hash Join (cost=15,139.30..893,131.79 rows=45,641 width=60) (actual rows= loops=)

  • Hash Cond: (at.projectid = project5.id)
10. 0.000 0.000 ↓ 0.0

Hash Left Join (cost=14,930.85..892,765.19 rows=60,133 width=64) (actual rows= loops=)

  • Hash Cond: (ts_3.id = ts_2.id)
11. 0.000 0.000 ↓ 0.0

Hash Join (cost=4,049.03..881,056.54 rows=60,133 width=52) (actual rows= loops=)

  • Hash Cond: (at.projectid = pj_1.id)
12. 0.000 0.000 ↓ 0.0

Append (cost=3,852.67..854,582.18 rows=2,080,611 width=1,052) (actual rows= loops=)

13. 0.000 0.000 ↓ 0.0

Result (cost=3,852.67..302,687.99 rows=1,453,026 width=1,052) (actual rows= loops=)

14. 0.000 0.000 ↓ 0.0

Append (cost=3,852.67..280,892.60 rows=1,453,026 width=1,044) (actual rows= loops=)

15. 0.000 0.000 ↓ 0.0

Hash Left Join (cost=3,852.67..266,362.35 rows=1,453,025 width=3,526) (actual rows= loops=)

  • Hash Cond: ((at.projectid = ptm.projectid) AND (at.userid = ptm.userid) AND (at.entrydate = ptma.date))
16.          

Initplan (for Hash Left Join)

17. 0.000 0.000 ↓ 0.0

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

18. 0.000 0.000 ↓ 0.0

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

19. 0.000 0.000 ↓ 0.0

Hash Left Join (cost=3,487.94..131,592.79 rows=1,453,025 width=2,866) (actual rows= loops=)

  • Hash Cond: (at.taskid = tk_1.id)
20. 0.000 0.000 ↓ 0.0

Hash Left Join (cost=3,371.14..127,660.17 rows=1,453,025 width=2,862) (actual rows= loops=)

  • Hash Cond: (at.billingrateid = br.id)
21. 0.000 0.000 ↓ 0.0

Hash Left Join (cost=3,370.09..115,893.95 rows=1,453,025 width=2,728) (actual rows= loops=)

  • Hash Cond: (pbr.id = pbrh.projectbillingrateid)
  • Join Filter: ((at.entrydate >= pbrh.effectivedate) AND (at.entrydate <= pbrh.enddate))
22. 0.000 0.000 ↓ 0.0

Hash Left Join (cost=3,229.74..88,702.14 rows=1,453,025 width=2,733) (actual rows= loops=)

  • Hash Cond: ((at.projectid = pbr.projectid) AND (at.billingrateid = pbr.billingrateid))
  • Join Filter: (((pbr.billingrateid = $3) AND (at.userid = pbr.userid)) OR ((pbr.billingrateid <> $4) AND (pbr.userid IS NULL)))
23. 0.000 0.000 ↓ 0.0

Hash Left Join (cost=3,075.99..48,005.22 rows=1,453,025 width=2,717) (actual rows= loops=)

  • Hash Cond: (at.projectid = pj_2.id)
24. 0.000 0.000 ↓ 0.0

Hash Join (cost=2,866.39..43,974.24 rows=1,453,025 width=2,713) (actual rows= loops=)

  • Hash Cond: (at.timesheetid = ts_3.id)
25. 0.000 0.000 ↓ 0.0

Seq Scan on dm_projecttimeallocation_facts at (cost=0.00..37,293.46 rows=1,453,031 width=2,701) (actual rows= loops=)

  • Filter: ((timeoffcodeid IS NULL) AND (duration IS NOT NULL))
26. 0.000 0.000 ↓ 0.0

Hash (cost=1,788.95..1,788.95 rows=86,195 width=28) (actual rows= loops=)

27. 0.000 0.000 ↓ 0.0

Seq Scan on timesheet ts_3 (cost=0.00..1,788.95 rows=86,195 width=28) (actual rows= loops=)

28. 0.000 0.000 ↓ 0.0

Hash (cost=181.49..181.49 rows=2,249 width=8) (actual rows= loops=)

29. 0.000 0.000 ↓ 0.0

Seq Scan on project pj_2 (cost=0.00..181.49 rows=2,249 width=8) (actual rows= loops=)

30. 0.000 0.000 ↓ 0.0

Hash (cost=104.15..104.15 rows=3,307 width=40) (actual rows= loops=)

31. 0.000 0.000 ↓ 0.0

Seq Scan on projectbillingrate pbr (cost=0.00..104.15 rows=3,307 width=40) (actual rows= loops=)

  • Filter: ((billingrateid = $3) OR ((billingrateid <> $4) AND (userid IS NULL)))
32. 0.000 0.000 ↓ 0.0

Hash (cost=85.71..85.71 rows=4,371 width=31) (actual rows= loops=)

33. 0.000 0.000 ↓ 0.0

Seq Scan on projectbillingratehistory pbrh (cost=0.00..85.71 rows=4,371 width=31) (actual rows= loops=)

34. 0.000 0.000 ↓ 0.0

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

35. 0.000 0.000 ↓ 0.0

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

36. 0.000 0.000 ↓ 0.0

Hash (cost=77.47..77.47 rows=3,147 width=8) (actual rows= loops=)

37. 0.000 0.000 ↓ 0.0

Seq Scan on task tk_1 (cost=0.00..77.47 rows=3,147 width=8) (actual rows= loops=)

38. 0.000 0.000 ↓ 0.0

Hash (cost=313.88..313.88 rows=1,020 width=44) (actual rows= loops=)

39. 0.000 0.000 ↓ 0.0

Hash Join (cost=291.00..313.88 rows=1,020 width=44) (actual rows= loops=)

  • Hash Cond: (ptma.projectteammemberid = ptm.id)
40. 0.000 0.000 ↓ 0.0

Seq Scan on projectteammemberallocation ptma (cost=0.00..20.20 rows=1,020 width=52) (actual rows= loops=)

41. 0.000 0.000 ↓ 0.0

Hash (cost=169.89..169.89 rows=9,689 width=24) (actual rows= loops=)

42. 0.000 0.000 ↓ 0.0

Seq Scan on projectteammember ptm (cost=0.00..169.89 rows=9,689 width=24) (actual rows= loops=)

43. 0.000 0.000 ↓ 0.0

Subquery Scan on *SELECT* 2_1 (cost=0.00..0.00 rows=1 width=1,044) (actual rows= loops=)

44. 0.000 0.000 ↓ 0.0

Result (cost=0.00..0.00 rows=0 width=1,044) (actual rows= loops=)

  • One-Time Filter: false
45. 0.000 0.000 ↓ 0.0

Subquery Scan on *SELECT* 3 (cost=2.77..14.46 rows=1 width=1,052) (actual rows= loops=)

46. 0.000 0.000 ↓ 0.0

Nested Loop (cost=2.77..14.45 rows=1 width=4,042) (actual rows= loops=)

  • Join Filter: (((ee.amount * ee.exchangevalue) * exchangerate_1.exchangevalue) IS NOT NULL)
47.          

Initplan (for Nested Loop)

48. 0.000 0.000 ↓ 0.0

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

49. 0.000 0.000 ↓ 0.0

Hash Join (cost=1.62..13.15 rows=1 width=154) (actual rows= loops=)

  • Hash Cond: (ex_1.reimbursementcurrencyid = exchangerate_1.fixedcurrencyid)
  • Join Filter: ((ex_1.expensedate >= exchangerate_1.effectivedate) AND (ex_1.expensedate <= exchangerate_1.enddate))
50. 0.000 0.000 ↓ 0.0

Seq Scan on expense ex_1 (cost=0.00..11.10 rows=110 width=138) (actual rows= loops=)

51. 0.000 0.000 ↓ 0.0

Hash (cost=1.61..1.61 rows=1 width=32) (actual rows= loops=)

52. 0.000 0.000 ↓ 0.0

Seq Scan on exchangerate exchangerate_1 (cost=0.00..1.61 rows=1 width=32) (actual rows= loops=)

  • Filter: (variablecurrencyid = $2)
53. 0.000 0.000 ↓ 0.0

Index Scan using ixeeexpenseid on expenseentry ee (cost=0.14..0.26 rows=1 width=3,165) (actual rows= loops=)

  • Index Cond: (expenseid = ex_1.id)
54. 0.000 0.000 ↓ 0.0

Subquery Scan on *SELECT* 4 (cost=0.00..0.01 rows=1 width=1,052) (actual rows= loops=)

55. 0.000 0.000 ↓ 0.0

Result (cost=0.00..0.00 rows=0 width=1,044) (actual rows= loops=)

  • One-Time Filter: false
56. 0.000 0.000 ↓ 0.0

Subquery Scan on *SELECT* 5 (cost=192,766.34..551,879.73 rows=627,583 width=1,037) (actual rows= loops=)

57. 0.000 0.000 ↓ 0.0

Hash Right Join (cost=192,766.34..542,465.98 rows=627,583 width=1,029) (actual rows= loops=)

  • Hash Cond: (bi2m.billingitemid = bi.id)
58.          

Initplan (for Hash Right Join)

59. 0.000 0.000 ↓ 0.0

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

60. 0.000 0.000 ↓ 0.0

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

61. 0.000 0.000 ↓ 0.0

Index Scan using ixbimbillingitemidkey on billingitem2metadata bi2m (cost=0.43..326,987.50 rows=1,454,411 width=32) (actual rows= loops=)

62. 0.000 0.000 ↓ 0.0

Hash (cost=184,895.57..184,895.57 rows=626,987 width=269) (actual rows= loops=)

63. 0.000 0.000 ↓ 0.0

Hash Left Join (cost=46,444.03..184,895.57 rows=626,987 width=269) (actual rows= loops=)

  • Hash Cond: (bi.id = iibi.billingitemid)
64. 0.000 0.000 ↓ 0.0

Hash Left Join (cost=46,409.95..183,215.66 rows=626,987 width=253) (actual rows= loops=)

  • Hash Cond: (bi.id = aggm.billingitemid)
  • Filter: (aggm.uri IS NULL)
65. 0.000 0.000 ↓ 0.0

Hash Left Join (cost=46,407.80..177,882.18 rows=1,421,685 width=253) (actual rows= loops=)

  • Hash Cond: (bidm.timesheetid = t.id)
66. 0.000 0.000 ↓ 0.0

Hash Left Join (cost=43,541.42..171,283.69 rows=1,421,685 width=241) (actual rows= loops=)

  • Hash Cond: (pbr_1.id = pbrh_1.projectbillingrateid)
  • Join Filter: ((bi.entrydate >= pbrh_1.effectivedate) AND (bi.entrydate <= pbrh_1.enddate))
67. 0.000 0.000 ↓ 0.0

Hash Left Join (cost=43,401.07..144,675.34 rows=1,421,685 width=253) (actual rows= loops=)

  • Hash Cond: ((bidm.projectid = pbr_1.projectid) AND (bidm.billingrateid = pbr_1.billingrateid))
  • Join Filter: (((pbr_1.billingrateid = $0) AND (bidm.userid = pbr_1.userid)) OR ((pbr_1.billingrateid <> $1) AND (pbr_1.userid IS NULL)))
68. 0.000 0.000 ↓ 0.0

Hash Left Join (cost=43,247.31..104,862.09 rows=1,421,685 width=253) (actual rows= loops=)

  • Hash Cond: (bidm.billingrateid = br_1.id)
69. 0.000 0.000 ↓ 0.0

Hash Join (cost=43,246.27..93,353.26 rows=1,421,685 width=119) (actual rows= loops=)

  • Hash Cond: (bidm.projectid = pj_3.id)
70. 0.000 0.000 ↓ 0.0

Hash Join (cost=43,127.14..89,495.17 rows=1,421,685 width=119) (actual rows= loops=)

  • Hash Cond: (bidm.billingitemid = bi.id)
  • Join Filter: (CASE WHEN (bidm.billingtypeuri = 'urn:replicon:billing-item-type:timesheet'::text) THEN bi.amount ELSE 0.0000::numeric(19,4) END IS NOT NULL)
71. 0.000 0.000 ↓ 0.0

Seq Scan on billingitem2denormalizedmetadata bidm (cost=0.00..42,553.71 rows=1,453,071 width=108) (actual rows= loops=)

  • Filter: (userid IS NOT NULL)
72. 0.000 0.000 ↓ 0.0

Hash (cost=25,267.29..25,267.29 rows=1,428,788 width=27) (actual rows= loops=)

73. 0.000 0.000 ↓ 0.0

Seq Scan on billingitem2 bi (cost=0.00..25,267.29 rows=1,428,788 width=27) (actual rows= loops=)

  • Filter: isbillable
74. 0.000 0.000 ↓ 0.0

Hash (cost=91.02..91.02 rows=2,249 width=4) (actual rows= loops=)

75. 0.000 0.000 ↓ 0.0

Index Only Scan using project_pkey on project pj_3 (cost=0.28..91.02 rows=2,249 width=4) (actual rows= loops=)

76. 0.000 0.000 ↓ 0.0

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

77. 0.000 0.000 ↓ 0.0

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

78. 0.000 0.000 ↓ 0.0

Hash (cost=104.15..104.15 rows=3,307 width=40) (actual rows= loops=)

79. 0.000 0.000 ↓ 0.0

Seq Scan on projectbillingrate pbr_1 (cost=0.00..104.15 rows=3,307 width=40) (actual rows= loops=)

  • Filter: ((billingrateid = $0) OR ((billingrateid <> $1) AND (userid IS NULL)))
80. 0.000 0.000 ↓ 0.0

Hash (cost=85.71..85.71 rows=4,371 width=24) (actual rows= loops=)

81. 0.000 0.000 ↓ 0.0

Seq Scan on projectbillingratehistory pbrh_1 (cost=0.00..85.71 rows=4,371 width=24) (actual rows= loops=)

82. 0.000 0.000 ↓ 0.0

Hash (cost=1,788.95..1,788.95 rows=86,195 width=28) (actual rows= loops=)

83. 0.000 0.000 ↓ 0.0

Seq Scan on timesheet t (cost=0.00..1,788.95 rows=86,195 width=28) (actual rows= loops=)

84. 0.000 0.000 ↓ 0.0

Hash (cost=2.14..2.14 rows=1 width=71) (actual rows= loops=)

85. 0.000 0.000 ↓ 0.0

Index Scan using ixbiminvoicinghint on billingitem2metadata aggm (cost=0.12..2.14 rows=1 width=71) (actual rows= loops=)

86. 0.000 0.000 ↓ 0.0

Hash (cost=20.70..20.70 rows=1,070 width=32) (actual rows= loops=)

87. 0.000 0.000 ↓ 0.0

Seq Scan on invoiceitembillingitems iibi (cost=0.00..20.70 rows=1,070 width=32) (actual rows= loops=)

88. 0.000 0.000 ↓ 0.0

Hash (cost=195.55..195.55 rows=65 width=4) (actual rows= loops=)

89. 0.000 0.000 ↓ 0.0

Seq Scan on project pj_1 (cost=0.00..195.55 rows=65 width=4) (actual rows= loops=)

  • Filter: (programid = ANY ('{321b534f-45e8-40c5-9af0-8a70128627e4,ea8af419-845e-41b7-8cf6-0ebb3ef291d0,93b1789e-c371-4fe8-a12e-40b30c8e927b,0c3ddab1-83ec-4cec-b0e3-6b4cd0e5d35a,7fdc4d09-9fcd-4c6d-890b-7656169646bf}'::uuid[]))
90. 0.000 0.000 ↓ 0.0

Hash (cost=9,804.38..9,804.38 rows=86,195 width=28) (actual rows= loops=)

91. 0.000 0.000 ↓ 0.0

Hash Join (cost=2,866.39..9,804.38 rows=86,195 width=28) (actual rows= loops=)

  • Hash Cond: (tslist_1.timesheetid = ts_2.id)
92. 0.000 0.000 ↓ 0.0

Seq Scan on dm_timesheetlist_facts tslist_1 (cost=0.00..6,705.53 rows=88,553 width=20) (actual rows= loops=)

93. 0.000 0.000 ↓ 0.0

Hash (cost=1,788.95..1,788.95 rows=86,195 width=24) (actual rows= loops=)

94. 0.000 0.000 ↓ 0.0

Seq Scan on timesheet ts_2 (cost=0.00..1,788.95 rows=86,195 width=24) (actual rows= loops=)

95. 0.000 0.000 ↓ 0.0

Hash (cost=187.11..187.11 rows=1,707 width=4) (actual rows= loops=)

96. 0.000 0.000 ↓ 0.0

Seq Scan on project project5 (cost=0.00..187.11 rows=1,707 width=4) (actual rows= loops=)

  • Filter: (projectstatuslabelid = ANY ('{22e9c44c-f33f-4840-8b6d-638837469dd8,f6918709-d5cf-436b-b0ff-2191cd2dd6a9}'::uuid[]))
97. 0.000 0.000 ↓ 0.0

Hash (cost=50.91..50.91 rows=81 width=8) (actual rows= loops=)

98. 0.000 0.000 ↓ 0.0

Hash Join (cost=26.07..50.91 rows=81 width=8) (actual rows= loops=)

  • Hash Cond: ("*SELECT* 1".expenseid = ex.id)
99. 0.000 0.000 ↓ 0.0

Append (cost=13.60..38.21 rows=81 width=8) (actual rows= loops=)

100. 0.000 0.000 ↓ 0.0

Subquery Scan on *SELECT* 1 (cost=13.60..25.81 rows=1 width=8) (actual rows= loops=)

101. 0.000 0.000 ↓ 0.0

Hash Anti Join (cost=13.60..25.80 rows=1 width=475) (actual rows= loops=)

  • Hash Cond: (dm_expenselist_facts.expenseid = dm_expenselist_realtime_facts.expenseid)
102. 0.000 0.000 ↓ 0.0

Seq Scan on dm_expenselist_facts (cost=0.00..11.60 rows=160 width=8) (actual rows= loops=)

103. 0.000 0.000 ↓ 0.0

Hash (cost=11.60..11.60 rows=160 width=4) (actual rows= loops=)

104. 0.000 0.000 ↓ 0.0

Seq Scan on dm_expenselist_realtime_facts (cost=0.00..11.60 rows=160 width=4) (actual rows= loops=)

105. 0.000 0.000 ↓ 0.0

Subquery Scan on *SELECT* 2 (cost=0.00..12.40 rows=80 width=8) (actual rows= loops=)

106. 0.000 0.000 ↓ 0.0

Seq Scan on dm_expenselist_realtime_facts dm_expenselist_realtime_facts_1 (cost=0.00..11.60 rows=80 width=475) (actual rows= loops=)

  • Filter: (NOT deleted)
107. 0.000 0.000 ↓ 0.0

Hash (cost=11.10..11.10 rows=110 width=4) (actual rows= loops=)

108. 0.000 0.000 ↓ 0.0

Seq Scan on expense ex (cost=0.00..11.10 rows=110 width=4) (actual rows= loops=)

109. 0.000 0.000 ↓ 0.0

Hash (cost=64.58..64.58 rows=1,858 width=5) (actual rows= loops=)

110. 0.000 0.000 ↓ 0.0

Seq Scan on userinfo ui_1 (cost=0.00..64.58 rows=1,858 width=5) (actual rows= loops=)

111.          

Initplan (for Sort)

112. 0.000 0.000 ↓ 0.0

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

113. 0.000 0.000 ↓ 0.0

Nested Loop Left Join (cost=3.63..12.07 rows=1 width=3,019) (actual rows= loops=)

114. 0.000 0.000 ↓ 0.0

Nested Loop Left Join (cost=3.35..11.76 rows=1 width=303) (actual rows= loops=)

115. 0.000 0.000 ↓ 0.0

Nested Loop Left Join (cost=1.26..7.42 rows=1 width=311) (actual rows= loops=)

116. 0.000 0.000 ↓ 0.0

Nested Loop Left Join (cost=1.12..7.24 rows=1 width=315) (actual rows= loops=)

117. 0.000 0.000 ↓ 0.0

Nested Loop Left Join (cost=0.84..4.94 rows=1 width=285) (actual rows= loops=)

118. 0.000 0.000 ↓ 0.0

Nested Loop Left Join (cost=0.70..4.78 rows=1 width=171) (actual rows= loops=)

119. 0.000 0.000 ↓ 0.0

Nested Loop Left Join (cost=0.43..2.48 rows=1 width=127) (actual rows= loops=)

120. 0.000 0.000 ↓ 0.0

Nested Loop Left Join (cost=0.28..2.32 rows=1 width=116) (actual rows= loops=)

121. 0.000 0.000 ↓ 0.0

CTE Scan on eexpensecostbilling2_facts0cte imeexpensecostbilling2_facts12 (cost=0.00..0.02 rows=1 width=61) (actual rows= loops=)

122. 0.000 0.000 ↓ 0.0

Index Scan using project_pkey on project pj (cost=0.28..2.30 rows=1 width=63) (actual rows= loops=)

  • Index Cond: (imeexpensecostbilling2_facts12.projectid7 = id)
123. 0.000 0.000 ↓ 0.0

Index Scan using program_pkey on program (cost=0.14..0.16 rows=1 width=43) (actual rows= loops=)

  • Index Cond: (pj.programid = id)
124. 0.000 0.000 ↓ 0.0

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

  • Index Cond: (imeexpensecostbilling2_facts12.userid1 = id)
125. 0.000 0.000 ↓ 0.0

Index Scan using employeetype_pkey on employeetype employeetype9 (cost=0.13..0.15 rows=1 width=122) (actual rows= loops=)

  • Index Cond: (ui.employeetypeid = id)
126. 0.000 0.000 ↓ 0.0

Index Scan using task_pkey on task tk (cost=0.28..2.30 rows=1 width=34) (actual rows= loops=)

  • Index Cond: (imeexpensecostbilling2_facts12.taskid8 = id)
127. 0.000 0.000 ↓ 0.0

Index Scan using uix3er_currencyideffectivedate on exchangerate (cost=0.14..0.18 rows=1 width=4) (actual rows= loops=)

  • Index Cond: ((variablecurrencyid = $7) AND (tk.estimatedcostcurrencyid = fixedcurrencyid) AND (('now'::cstring)::date >= effectivedate))
  • Filter: (('now'::cstring)::date <= enddate)
128. 0.000 0.000 ↓ 0.0

Nested Loop (cost=2.09..4.33 rows=1 width=24) (actual rows= loops=)

129. 0.000 0.000 ↓ 0.0

Nested Loop Left Join (cost=1.67..3.86 rows=1 width=24) (actual rows= loops=)

130. 0.000 0.000 ↓ 0.0

Index Only Scan using timesheet_pkey on timesheet ts (cost=0.42..2.44 rows=1 width=16) (actual rows= loops=)

  • Index Cond: (id = imeexpensecostbilling2_facts12.timesheetid9)
131. 0.000 0.000 ↓ 0.0

Nested Loop (cost=1.26..1.42 rows=1 width=24) (actual rows= loops=)

132. 0.000 0.000 ↓ 0.0

Nested Loop (cost=0.84..0.96 rows=1 width=24) (actual rows= loops=)

133. 0.000 0.000 ↓ 0.0

Index Scan using timesheetapprovalhistorylastsubmit_pkey on timesheetapprovalhistorylastsubmit tahls (cost=0.42..0.44 rows=1 width=20) (actual rows= loops=)

  • Index Cond: (ts.id = timesheetid)
134. 0.000 0.000 ↓ 0.0

Index Scan using uixtahsn on timesheetapprovalhistory ta (cost=0.42..0.52 rows=1 width=12) (actual rows= loops=)

  • Index Cond: (serialnumber = tahls.lastsubmitserialnumber)
135. 0.000 0.000 ↓ 0.0

Index Scan using timesheet_pkey on timesheet ts_1 (cost=0.42..0.46 rows=1 width=16) (actual rows= loops=)

  • Index Cond: (id = tahls.timesheetid)
  • Filter: (approvalstatus = ANY ('{1,2}'::integer[]))
136. 0.000 0.000 ↓ 0.0

Index Only Scan using ixdtslsftimesheetid on dm_timesheetlist_facts tslist (cost=0.42..0.47 rows=1 width=16) (actual rows= loops=)

  • Index Cond: (timesheetid = ts.id)
137. 0.000 0.000 ↓ 0.0

Index Scan using login_pkey on login (cost=0.28..0.31 rows=1 width=11) (actual rows= loops=)

  • Index Cond: (ui.id = userid)