Re: Speed up the query

From: Andreas Kretschmer <akretschmer(at)spamfence(dot)net>
To: pgsql-performance(at)postgresql(dot)org
Subject: Re: Speed up the query
Date: 2013-12-01 12:27:02
Message-ID: 20131201122702.GA26157@tux
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-performance

Torsten Förtsch <torsten(dot)foertsch(at)gmx(dot)net> wrote:
> I'd try 2 things:
>
> 1) set work_mem to ~100Mb. You don't have to do that globally in
> postgresql.conf. You can set it for the current session only.
>
> set work_mem to '100MB';
>
> Then run your query.
>
> 2) change the common table expression to a subquery:

Yeah, agree.

Andreas
--
Really, I'm not out to destroy Microsoft. That will just be a completely
unintentional side effect. (Linus Torvalds)
"If I was god, I would recompile penguin with --enable-fly." (unknown)
Kaufbach, Saxony, Germany, Europe. N 51.05082°, E 13.56889°

In response to

Browse pgsql-performance by date

  From Date Subject
Next Message Andreas Kretschmer 2013-12-01 12:29:47 Re: Speed up the query
Previous Message Hengky Liwandouw 2013-12-01 12:25:38 Re: Speed up the query