Re: [PERFORM] Slow Query

2015-08-13 Thread robbyc
Hi, Doing this returns 0 records On Thu, Aug 13, 2015 at 7:22 PM, 林士博 [via PostgreSQL] < ml-node+s1045698n5862008...@n5.nabble.com> wrote: > In the 'not exists' cluster, you do not have to search table "Vacancy as > v" again. > I think it would be faster to use the outer Vacancy table as below.

Re: [PERFORM] Slow Query

2015-08-12 Thread robbyc
rtment"."ClientID" = 263) WHERE "Vacancy"."ClientID" = 263 AND NOT EXISTS ( SELECT 1 FROM "Vacancy" as "v" JOIN "CategoryOption_TableRow" "ct126" on ( "ct126"."Category_TableID&quo

Re: [PERFORM] Slow Query

2015-08-11 Thread robbyc
d, Aug 12, 2015 at 12:34 PM, robbyc <[hidden email] > <http:///user/SendEmail.jtp?type=node&node=5861839&i=0>> wrote: > >> Hi, >> >> I am new to optimizing queries and i'm getting a slow running time >> (~1.5secs) with the following

[PERFORM] Slow Query

2015-08-11 Thread robbyc
Hi, I am new to optimizing queries and i'm getting a slow running time (~1.5secs) with the following SQL: SELECT distinct("Vacancy"."ID"), "Vacancy"."JobTitle", "Vacancy"."DateCreated", "Vacancy"."CustomAccess" , "Department"."Name" as "Department", list("Occupation"."Name") as "Occupation", "Vac