From: | Oliver Kohll <oliver(at)agilechilli(dot)com> |
---|---|
To: | pgsql-general(at)lists(dot)postgresql(dot)org |
Subject: | ProjectSet |
Date: | 2018-08-02 09:17:22 |
Message-ID: | CAMS=m5KW59UHbwAU6pLWPd=Er5sydc-B_dv9X5AeZTpGRv3EAQ@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-general |
Hi,
I've just been running explain analyze on a slow query and came across
something new to me - a node type of ProjectSet in the plan. What is that?
The plan is here: https://explain.depesz.com/s/4rqA
The query does a cross join of two tables to get every row in one combined
with every row in the other, then runs the similarity function to compare
text in them. The full query is below, apologies for the different
obfuscation to the plan, if that's an issue let me know.
Is there an explanation of ProjectSet anywhere? I can't see one with a
quick google or search of these archives.
Cheers
Oliver
---
SELECT table1.id,
similarity(table2.field1::text, regexp_matches(table1.field3::text,
'product.ame:s*([^-]*)'::text, 'g'::text)::character
varying(100000)::text)::double precision AS similarityscore,
table1.ourid_g3a11eruac8ct55b,
regexp_matches(table1.field3::text, 'product.ame:s*([^-]*)'::text,
'g'::text)::character varying(100000) AS products,
table2.field1,
table2.field2,
table2.abaccount
FROM table1,
table2
WHERE lower(table2.statusofingredient::text) < '6'::text AND
lower(table2.statusofproduct::text) < '5'::text AND table1.fsacreated >=
(date_trunc('day'::text, now()) - '30 days'::interval) AND
lower(table2.bought::text) = 'bought'::text
ORDER BY table1.id DESC NULLS LAST;
From | Date | Subject | |
---|---|---|---|
Next Message | ik | 2018-08-02 09:32:26 | Re: Adding terminal title support for psqlrc |
Previous Message | Alexandru Lazarev | 2018-08-02 05:53:15 | Who and How is responsible for released installations packages and 3rd party packs? (e.g. on https://yum.postgresql.org/9.6/redhat/rhel-7.3-x86_64/) |