From: | Rob Imig <rimig88(at)gmail(dot)com> |
---|---|
To: | Sterpu Victor <victor(at)caido(dot)ro>, PostgreSQL General <pgsql-general(at)postgresql(dot)org> |
Subject: | Re: Slow query when the select list is big |
Date: | 2016-05-09 06:03:10 |
Message-ID: | CANcrS5oV8JJxtKV1kmPn9q+WfgzwAM1Co07vZXSrmUcFBbWHOA@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-general |
Can you share the full query and output of EXPLAIN ? Not much data here
yet.
On Mon, May 9, 2016 at 6:58 AM Sterpu Victor <victor(at)caido(dot)ro> wrote:
> I have a big query that takes about 7 seconds to run(time sending the data
> to the client is not counted).
> Postgres uses 100% of 1 CPU when solving this query. I tried to run the
> query on a HDD and on a SSD with no difference. HDD show about 10% usage
> while the query runs.
>
> The query has a big "select" list and no "group by" clause. If I delete
> all selects except one the query runs in under a second(it doesn't matter
> what field remains selected).
> It seems that the query is slow because of the long select, can I do
> something to make the query faster?
>
> Thank you.
>
>
From | Date | Subject | |
---|---|---|---|
Next Message | Sterpu Victor | 2016-05-09 06:09:09 | Re: Slow query when the select list is big |
Previous Message | Sterpu Victor | 2016-05-09 05:57:45 | Slow query when the select list is big |