We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Version of PEV2: xxxx PEV2 version 1.12.1 Copy the failing plan
Nested Loop (cost=1305.69..1734.14 rows=1 width=55) (actual time=10.362..23.273 rows=42 loops=1) Output: r.tableeventid, events.seasonid, events.episodeid, events.seriesid, (CASE WHEN (events.partnumber > 1) THEN events.partnumber ELSE '1'::bigint END), (CASE WHEN (events.parttotal > 1) THEN events.parttotal ELSE '1'::bigint END), r.deleterequesttime, r.state Buffers: shared hit=2294 CTE enableseries -> Index Scan using series_unicity on public.series (cost=0.43..8.45 rows=1 width=147) (actual time=0.017..0.018 rows=1 loops=1) Output: series.id, series.userid, series.seriesid, series.deviceid, series.deletedeviceid, series.userid_str, series.creationtime, series.modif icationtime, series.firstrun, series.customerdefinedparameters, series.startmargin, series.endmargin, series.rollingepisodenumber, series.windowutcbeginti me, series.windowutcendtime, series.windowtime, series.channelrec, series.recordfromseasonid, series.recordfromseasonepisodeid, series.tokeep, series.last epgupdatetime, series.lastseriesupdatetime Index Cond: ((series.userid = 416436) AND ((series.seriesid)::text = 'service_0026_4'::text)) Buffers: shared hit=4 CTE enabledseasons -> Unique (cost=8.57..8.63 rows=2 width=583) (actual time=0.054..0.059 rows=2 loops=1) Output: (('-1'::integer)::bigint), (('-1'::integer)::bigint), "*SELECT* 1".seasonid, "*SELECT* 1".episodeid, "*SELECT* 1".firstrun, "*SELECT* 1 ".channelrec, "*SELECT* 1".windowutcbegintime, "*SELECT* 1".windowutcendtime, "*SELECT* 1".tokeep, "*SELECT* 1".windowtime, "*SELECT* 1".windowtz, "*SELEC T* 1".automaticallycreated Buffers: shared hit=8 -> Sort (cost=8.57..8.57 rows=2 width=583) (actual time=0.053..0.056 rows=2 loops=1) Output: (('-1'::integer)::bigint), (('-1'::integer)::bigint), "*SELECT* 1".seasonid, "*SELECT* 1".episodeid, "*SELECT* 1".firstrun, "*SEL ECT* 1".channelrec, "*SELECT* 1".windowutcbegintime, "*SELECT* 1".windowutcendtime, "*SELECT* 1".tokeep, "*SELECT* 1".windowtime, "*SELECT* 1".windowtz, " *SELECT* 1".automaticallycreated Sort Key: (('-1'::integer)::bigint), (('-1'::integer)::bigint), "*SELECT* 1".seasonid, "*SELECT* 1".episodeid, "*SELECT* 1".firstrun, "*S ELECT* 1".channelrec, "*SELECT* 1".windowutcbegintime, "*SELECT* 1".windowutcendtime, "*SELECT* 1".tokeep, "*SELECT* 1".windowtime, "*SELECT* 1".windowtz, "*SELECT* 1".automaticallycreated Sort Method: quicksort Memory: 25kB Buffers: shared hit=8 -> Append (cost=0.43..8.56 rows=2 width=583) (actual time=0.040..0.047 rows=2 loops=1) Buffers: shared hit=8 -> Subquery Scan on "*SELECT* 1" (cost=0.43..8.51 rows=1 width=583) (actual time=0.039..0.042 rows=1 loops=1) Output: '-1'::integer, '-1'::integer, "*SELECT* 1".seasonid, "*SELECT* 1".episodeid, "*SELECT* 1".firstrun, "*SELECT* 1".chan nelrec, "*SELECT* 1".windowutcbegintime, "*SELECT* 1".windowutcendtime, "*SELECT* 1".tokeep, "*SELECT* 1".windowtime, "*SELECT* 1".windowtz, "*SELECT* 1". automaticallycreated Buffers: shared hit=8 -> Nested Loop (cost=0.43..8.49 rows=1 width=575) (actual time=0.038..0.041 rows=1 loops=1) Output: '-1'::integer, '-1'::integer, seasons.seasonid, seasons.episodeid, series_1.firstrun, COALESCE(seasons.channelr ec, series_1.channelrec), COALESCE(NULLIF(seasons.windowutcbegintime, '-1'::integer), series_1.windowutcbegintime), COALESCE(NULLIF(seasons.windowutcbegin time, '-1'::integer), series_1.windowutcendtime), COALESCE(seasons.tokeep, series_1.tokeep), COALESCE(NULLIF(seasons.windowtime, '-1'::integer), series_1. windowtime), date_part('timezone'::text, to_timestamp((COALESCE(NULLIF(seasons.windowtime, '-1'::integer), series_1.windowtime))::double precision)), seas ons.automaticallycreated Buffers: shared hit=8 -> CTE Scan on enableseries series_1 (cost=0.00..0.02 rows=1 width=550) (actual time=0.018..0.019 rows=1 loops=1) Output: series_1.id, series_1.userid, series_1.seriesid, series_1.deviceid, series_1.deletedeviceid, series_1.use rid_str, series_1.creationtime, series_1.modificationtime, series_1.firstrun, series_1.customerdefinedparameters, series_1.startmargin, series_1.endmargin , series_1.rollingepisodenumber, series_1.windowutcbegintime, series_1.windowutcendtime, series_1.windowtime, series_1.channelrec, series_1.recordfromseas onid, series_1.recordfromseasonepisodeid, series_1.tokeep, series_1.lastepgupdatetime, series_1.lastseriesupdatetime Buffers: shared hit=4 -> Index Scan using season_unicity on public.seasons (cost=0.43..8.45 rows=1 width=43) (actual time=0.012..0.013 rows =1 loops=1) Output: seasons.series_id, seasons.seasonid, seasons.episodeid, seasons.channelrec, seasons.creationtime, seasons .modificationtime, seasons.windowutcbegintime, seasons.windowutcendtime, seasons.tokeep, seasons.automaticallycreated, seasons.windowtime, seasons.channel recfromserie Index Cond: (seasons.series_id = series_1.id) Buffers: shared hit=4 -> CTE Scan on enableseries series_2 (cost=0.00..0.03 rows=1 width=583) (actual time=0.002..0.003 rows=1 loops=1) Output: series_2.recordfromseasonid, series_2.recordfromseasonepisodeid, NULL::bigint, NULL::bigint, series_2.firstrun, serie s_2.channelrec, series_2.windowutcbegintime, series_2.windowutcendtime, series_2.tokeep, series_2.windowtime, date_part('timezone'::text, to_timestamp((se ries_2.windowtime)::double precision)), true Filter: (series_2.recordfromseasonid <> '-1'::integer) CTE manualseasons -> CTE Scan on enabledseasons (cost=0.00..0.04 rows=1 width=8) (actual time=0.003..0.003 rows=0 loops=1) Output: enabledseasons.seasonid Filter: (NOT enabledseasons.automaticallycreated) Rows Removed by Filter: 2 -> Sort (cost=1186.50..1186.51 rows=5 width=725) (actual time=0.852..0.864 rows=124 loops=1) Output: NULL::character varying(400), NULL::character varying(64), events.tableeventid, events.utcstart, NULL::bigint, events.seasonid, events.ep isodeid, events.seriesid, NULL::boolean, (CASE WHEN (events.partnumber > 1) THEN events.partnumber ELSE '1'::bigint END), (CASE WHEN (events.parttotal > 1 ) THEN events.parttotal ELSE '1'::bigint END), NULL::boolean Sort Key: events.utcstart Sort Method: quicksort Memory: 42kB Buffers: shared hit=442 -> Nested Loop (cost=0.52..1186.44 rows=5 width=725) (actual time=0.626..0.816 rows=124 loops=1) Output: NULL::character varying(400), NULL::character varying(64), events.tableeventid, events.utcstart, NULL::bigint, events.seasonid, eve nts.episodeid, events.seriesid, NULL::boolean, CASE WHEN (events.partnumber > 1) THEN events.partnumber ELSE '1'::bigint END, CASE WHEN (events.parttotal > 1) THEN events.parttotal ELSE '1'::bigint END, NULL::boolean Join Filter: (((NOT s.firstrun) OR (s.firstrun AND events.firstrun)) AND (((s.channelrec)::text = ''::text) OR ((events.liveid_str)::text = ANY (string_to_array((s.channelrec)::text, ','::text)))) AND (((events.seasonid = s.seasonid) AND (s.seasonid >= 0) AND ((s.episodeid = '-1'::integer) OR (s.episodeid IS NULL) OR (events.episodeid >= s.episodeid)) AND (hashed SubPlan 4)) OR ((events.seasonid >= s.recordfromseasonid) AND (s.recordfromseason id >= 0) AND (NOT (hashed SubPlan 5)) AND ((s.recordfromseasonepisodeid = ANY ('{-1,0}'::bigint[])) OR (s.recordfromseasonepisodeid IS NULL) OR (events.se asonid > s.recordfromseasonid) OR ((events.episodeid >= s.recordfromseasonepisodeid) AND (events.seasonid = s.recordfromseasonid)))))) Rows Removed by Join Filter: 400 Buffers: shared hit=442 -> CTE Scan on enabledseasons s (cost=0.00..0.05 rows=1 width=549) (actual time=0.056..0.056 rows=2 loops=1) Output: s.recordfromseasonid, s.recordfromseasonepisodeid, s.seasonid, s.episodeid, s.firstrun, s.channelrec, s.windowutcbegintime, s .windowutcendtime, s.tokeep, s.windowtime, s.windowtz, s.automaticallycreated Filter: (((NOT s.firstrun) OR s.firstrun) AND ((s.seasonid >= 0) OR (s.recordfromseasonid >= 0))) Buffers: shared hit=8 -> Index Scan using idx_events_seriesid on public.events (cost=0.47..1171.32 rows=261 width=67) (actual time=0.015..0.335 rows=262 loops= 2) Output: events.liveid, events.utcstart, events.utcstop, events.utcrealstart, events.utcrealstop, events.recordstarttime, events.recor dstoptime, events.seriesid, events.eventid, events.customerdefinedparameters, events.archive, events.utcarchiveend, events.utcexpiration, events.utcexpira tioninit, events.npvrallowed, events.catchupallowed, events.startoverallowed, events.popularity, events.privatecopy, events.parentalcontrol, events.tablee ventid, events.numberextensions, events.extensiondurationindays, events.blacklistcode, events.utcbeginoffset, events.utcendoffset, events.eventname, event s.eventcategory, events.updatecounter, events.md5, events.updatedate, events.state, events.status, events.statusdescr, events.size, events.realduration, e vents.recordassetname, events.lastfailtime, events.numberofretry, events.specificusage, events.liveid_str, events.eventtype, events.recordrequesttime, eve nts.modificationtime, events.deleterequesttime, events.playingurl, events.callerid_str, events.deliverytype, events.pastrecord, events.jobdetails, events. eventsgroupid, events.extractprofile, events.extractpriority, events.seasonid, events.episodeid, events.firstrun, events.maxuserstartmargin, events.maxuse rstopmargin, events.partnumber, events.parttotal, events.nbjobattempts, events.sharedmode, events.copyid, events.eitid, events.eitstarttime, events.eitsto ptime Index Cond: ((events.seriesid)::text = 'service_0026_4'::text) Filter: ((events.eventtype = 2) AND ((hashed SubPlan 4) OR (NOT (hashed SubPlan 5)))) Buffers: shared hit=434 SubPlan 4 -> CTE Scan on manualseasons (cost=0.00..0.02 rows=1 width=8) (actual time=0.002..0.002 rows=0 loops=2) Output: manualseasons.seasonid SubPlan 5 -> CTE Scan on manualseasons manualseasons_1 (cost=0.00..0.02 rows=1 width=8) (actual time=0.000..0.000 rows=0 loops=2) Output: manualseasons_1.seasonid -> Bitmap Heap Scan on public.records r (cost=102.06..106.08 rows=1 width=18) (actual time=0.180..0.180 rows=0 loops=124) Output: r.tableeventid, r.deleterequesttime, r.state Recheck Cond: ((r.userid = 416436) AND (r.tableeventid = events.tableeventid)) Filter: ((r.deviceid)::text = ''::text) Heap Blocks: exact=42 Buffers: shared hit=1852 -> BitmapAnd (cost=102.06..102.06 rows=1 width=0) (actual time=0.178..0.178 rows=0 loops=124) Buffers: shared hit=1809 -> Bitmap Index Scan on idx_records_userid (cost=0.00..8.88 rows=574 width=0) (actual time=0.014..0.014 rows=320 loops=124) Index Cond: (r.userid = 416436) Buffers: shared hit=496 -> Bitmap Index Scan on idx_records_tableeventid (cost=0.00..92.79 rows=4830 width=0) (actual time=0.155..0.155 rows=3697 loops=124) Index Cond: (r.tableeventid = events.tableeventid) Buffers: shared hit=1313 Planning: Buffers: shared hit=13 Planning Time: 5.316 ms Execution Time: 23.377 ms (83 rows)
The text was updated successfully, but these errors were encountered:
No branches or pull requests
Version of PEV2: xxxx
PEV2 version 1.12.1
Copy the failing plan
The text was updated successfully, but these errors were encountered: