| Time |
Node |
| Node (ms) |
Percent |
| 31093.370 |
100.00% |
¶ |
Sort (cost=140.97..140.98 rows=4 width=207) (actual time=31093.367..31093.370 rows=3 loops=1)
Sort Key: view__domain_tldproducts.duration, productregioncost.cost
InitPlan
|
| 0.874 |
0.00% |
¶ |
-> Subquery Scan view__domain_tldproducts (cost=12.95..12.96 rows=1 width=0) (actual time=0.869..0.874 rows=1 loops=1)
|
| 0.866 |
0.00% |
¶ |
-> Sort (cost=12.95..12.95 rows=1 width=93) (actual time=0.865..0.866 rows=1 loops=1)
Sort Key: tldproducts.tld, tldproducts.purchasetype, productdetails.duration
|
| 0.845 |
0.00% |
¶ |
-> Nested Loop (cost=0.0..12.94 rows=1 width=93) (actual time=0.195..0.845 rows=1 loops=1)
|
| 0.802 |
0.00% |
¶ |
-> Nested Loop (cost=0.0..7.49 rows=1 width=81) (actual time=0.158..0.802 rows=1 loops=1)
|
| 0.706 |
0.00% |
¶ |
-> Seq Scan on tldproducts (cost=0.0..1.95 rows=1 width=19) (actual time=0.070..0.706 rows=1 loops=1)
Filter: (((tld)::text = (func__common__tld_from_domainname('sunonthesand.com'::character varying))::text) AND ((purchasetype)::text = 'intro'::text))
|
| 0.082 |
0.00% |
¶ |
-> Index Scan using productdesc_pkey on productdesc (cost=0.0..5.53 rows=1 width=62) (actual time=0.079..0.082 rows=1 loops=1)
Index Cond: ("outer".productid = productdesc.productid)
|
| 0.031 |
0.00% |
¶ |
-> Index Scan using productdetails_pkey on productdetails (cost=0.0..5.44 rows=1 width=20) (actual time=0.029..0.031 rows=1 loops=1)
Index Cond: ("outer".productid = productdetails.productid)
|
| 0.813 |
0.00% |
¶ |
-> Subquery Scan view__domain_tldproducts (cost=12.95..12.96 rows=1 width=16) (actual time=0.808..0.813 rows=1 loops=1)
|
| 0.806 |
0.00% |
¶ |
-> Sort (cost=12.95..12.95 rows=1 width=93) (actual time=0.804..0.806 rows=1 loops=1)
Sort Key: tldproducts.tld, tldproducts.purchasetype, productdetails.duration
|
| 0.786 |
0.00% |
¶ |
-> Nested Loop (cost=0.0..12.94 rows=1 width=93) (actual time=0.138..0.786 rows=1 loops=1)
|
| 0.764 |
0.00% |
¶ |
-> Nested Loop (cost=0.0..7.49 rows=1 width=81) (actual time=0.122..0.764 rows=1 loops=1)
|
| 0.708 |
0.00% |
¶ |
-> Seq Scan on tldproducts (cost=0.0..1.95 rows=1 width=19) (actual time=0.075..0.708 rows=1 loops=1)
Filter: (((tld)::text = (func__common__tld_from_domainname('sunonthesand.com'::character varying))::text) AND ((purchasetype)::text = 'intro'::text))
|
| 0.041 |
0.00% |
¶ |
-> Index Scan using productdesc_pkey on productdesc (cost=0.0..5.53 rows=1 width=62) (actual time=0.038..0.041 rows=1 loops=1)
Index Cond: ("outer".productid = productdesc.productid)
|
| 0.011 |
0.00% |
¶ |
-> Index Scan using productdetails_pkey on productdetails (cost=0.0..5.44 rows=1 width=20) (actual time=0.009..0.011 rows=1 loops=1)
Index Cond: ("outer".productid = productdetails.productid)
|
| 31093.341 |
100.00% |
¶ |
-> Hash Join (cost=29.61..115.0 rows=4 width=207) (actual time=23268.446..31093.341 rows=3 loops=1)
Hash Cond: ("outer".productid = "inner".productid)
Join Filter: CASE WHEN ((subplan) AND (subplan)) THEN (("inner".purchasetype)::text = 'free'::text) WHEN $2 THEN ((("inner".purchasetype)::text = 'intro'::text) OR ((("inner". purchasetype)::text = 'new'::text) AND ("inner".duration <> $3))) ELSE (("inner".purchasetype)::text = 'new'::text) END
|
| 1.134 |
0.00% |
¶ |
-> Nested Loop (cost=5.67..18.48 rows=154 width=29) (actual time=0.238..1.134 rows=155 loops=1)
|
| 0.131 |
0.00% |
¶ |
-> Nested Loop (cost=0.0..7.03 rows=1 width=19) (actual time=0.104..0.131 rows=1 loops=1)
Join Filter: ("inner".regioncurrencyid = "outer".regioncurrencyid)
|
| 0.093 |
0.00% |
¶ |
-> Index Scan using members_pkey on members (cost=0.0..5.9 rows=1 width=8) (actual time=0.090..0.093 rows=1 loops=1)
Index Cond: (memberid = 2756918)
|
| 0.014 |
0.00% |
¶ |
-> Seq Scan on regioncurrency (cost=0.0..1.06 rows=6 width=11) (actual time=0.003..0.014 rows=6 loops=1)
|
| 0.499 |
0.00% |
¶ |
-> Bitmap Heap Scan on productregioncost (cost=5.67..10.46 rows=79 width=18) (actual time=0.126..0.499 rows=155 loops=1)
Recheck Cond: (productregioncost.regioncurrencyid = "outer".regioncurrencyid)
|
| 0.099 |
0.00% |
¶ |
-> Bitmap Index Scan on productregioncost_pkey (cost=0.0..5.67 rows=79 width=0) (actual time=0.099..0.099 rows=155 loops=1)
Index Cond: (productregioncost.regioncurrencyid = "outer".regioncurrencyid)
|
| 3.156 |
0.01% |
¶ |
-> Hash (cost=23.94..23.94 rows=5 width=190) (actual time=3.156..3.156 rows=8 loops=1)
|
| 3.129 |
0.01% |
¶ |
-> Subquery Scan view__domain_tldproducts (cost=23.87..23.94 rows=5 width=190) (actual time=3.093..3.129 rows=8 loops=1)
|
| 3.101 |
0.01% |
¶ |
-> Sort (cost=23.87..23.89 rows=5 width=93) (actual time=3.090..3.101 rows=8 loops=1)
Sort Key: tldproducts.tld, tldproducts.purchasetype, productdetails.duration
|
| 3.058 |
0.01% |
¶ |
-> Hash Join (cost=13.94..23.82 rows=5 width=93) (actual time=2.491..3.058 rows=8 loops=1)
Hash Cond: ("outer".productid = "inner".productid)
|
| 0.649 |
0.00% |
¶ |
-> Seq Scan on productdesc (cost=0.0..8.22 rows=322 width=62) (actual time=0.021..0.649 rows=322 loops=1)
|
| 1.873 |
0.01% |
¶ |
-> Hash (cost=13.92..13.92 rows=5 width=39) (actual time=1.873..1.873 rows=8 loops=1)
|
| 1.855 |
0.01% |
¶ |
-> Hash Join (cost=1.82..13.92 rows=5 width=39) (actual time=0.880..1.855 rows=8 loops=1)
Hash Cond: ("outer".productid = "inner".productid)
|
| 0.587 |
0.00% |
¶ |
-> Seq Scan on productdetails (cost=0.0..7.22 rows=322 width=20) (actual time=0.004..0.587 rows=322 loops=1)
|
| 0.745 |
0.00% |
¶ |
-> Hash (cost=1.81..1.81 rows=5 width=19) (actual time=0.745..0.745 rows=8 loops=1)
|
| 0.720 |
0.00% |
¶ |
-> Seq Scan on tldproducts (cost=0.0..1.81 rows=5 width=19) (actual time=0.075..0.720 rows=8 loops=1)
Filter: ((tld)::text = (func__common__tld_from_domainname('sunonthesand.com'::character varying))::text)
SubPlan
|
| 31085.648 |
99.98% |
¶ |
-> Result (cost=0.0..0.01 rows=1 width=0) (actual time=3885.704..3885.706 rows=1 loops=8)
|
| 1.288 |
0.00% |
¶ |
-> Nested Loop (cost=12.95..17.92 rows=1 width=0) (actual time=0.153..0.161 rows=1 loops=8)
|
| 0.784 |
0.00% |
¶ |
-> Sort (cost=12.95..12.95 rows=1 width=93) (actual time=0.096..0.098 rows=1 loops=8)
Sort Key: tldproducts.tld, tldproducts.purchasetype, productdetails.duration
|
| 0.748 |
0.00% |
¶ |
-> Nested Loop (cost=0.0..12.94 rows=1 width=93) (actual time=0.164..0.748 rows=1 loops=1)
|
| 0.731 |
0.00% |
¶ |
-> Nested Loop (cost=0.0..7.49 rows=1 width=81) (actual time=0.154..0.731 rows=1 loops=1)
|
| 0.679 |
0.00% |
¶ |
-> Seq Scan on tldproducts (cost=0.0..1.95 rows=1 width=19) (actual time=0.108..0.679 rows=1 loops=1)
Filter: (((tld)::text = (func__common__tld_from_domainname('sunonthesand.com'::character varying))::text) AND ((purchasetype)::text = 'free'::t ext))
|
| 0.042 |
0.00% |
¶ |
-> Index Scan using productdesc_pkey on productdesc (cost=0.0..5.53 rows=1 width=62) (actual time=0.039..0.042 rows=1 loops=1)
Index Cond: ("outer".productid = productdesc.productid)
|
| 0.008 |
0.00% |
¶ |
-> Index Scan using productdetails_pkey on productdetails (cost=0.0..5.44 rows=1 width=20) (actual time=0.006..0.008 rows=1 loops=1)
Index Cond: ("outer".productid = productdetails.productid)
|
| 0.408 |
0.00% |
¶ |
-> Index Scan using productregioncost_pkey on productregioncost prodcost (cost=0.0..4.94 rows=1 width=4) (actual time=0.049..0.051 rows=1 loops=8)
Index Cond: ((prodcost.productid = "outer".productid) AND (prodcost.regioncurrencyid = $0))
|
ANALYZEto update the server's statistics.EXPLAINand interpreting its output, see the Postgres documentation, in particular theEXPLAINandANALYZEreferences pages, and Using Explain.