Re: [GENERAL] Queries are taking way longer in 9.6 than 9.5 - Mailing list pgsql-general

From Chris Mair
Subject Re: [GENERAL] Queries are taking way longer in 9.6 than 9.5
Date
Msg-id dfa066c765ed68b8564a30322467e6dc@smtp.hushmail.com
Whole thread Raw
In response to Re: [GENERAL] Queries are taking way longer in 9.6 than 9.5  (Tomas Vondra <tomas.vondra@2ndquadrant.com>)
Responses Re: [GENERAL] Queries are taking way longer in 9.6 than 9.5
List pgsql-general
On 17/01/17 23:21, Tomas Vondra wrote:
> Hi,
>
> after looking at the explain plans again, I very much doubt those come from the same query. The reason is the 9.5
plancontains this part: 
>
>     ->  HashAggregate  (cost=67.54..68.12 rows=192 width=4)
>           Group Key: d.vip_patient_id
>           ->  Nested Loop  (cost=0.17..67.44 rows=192 width=4)
>                 ->  Index Scan using unq_user_name on tblcnaccounts ...
>                       Index Cond: ((user_name)::text = 'dddddd'::text)
>                 ->  Index Only Scan using idx_tblcndoctorpatientmap ...
>                       Index Cond: (master_user_id = a.master_user_id)
>
> while the 9.6 plan does not include anything like that, i.e. there's only a single aggregate at the top level,
withoutany group keys. Also, the SQL query you've provided does not include any GROUP BY clause, so I claim that those
plansare from two different queries. 

There's also a user_name = 'dddddd' that has become a user_name = 'rdoyleda' ...

Ravi, could you please send the current query you're testing and the explain analyze of that query on 9.5 and 9.6?

Bye,
Chris.





pgsql-general by date:

Previous
From: Tomas Vondra
Date:
Subject: Re: [GENERAL] Queries are taking way longer in 9.6 than 9.5
Next
From: Neslisah Demirci
Date:
Subject: [GENERAL] postgresql : could not serialize access due to read/writedependencies among transactions