Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.80) (envelope-from ) id 1V75kN-00048O-BW for pgsql-performance@arkaria.postgresql.org; Wed, 07 Aug 2013 15:33:59 +0000 Received: from localhost ([127.0.0.1] helo=postgresql.org) by malur.postgresql.org with smtp (Exim 4.80) (envelope-from ) id 1V75kM-0002xb-S5 for pgsql-performance@arkaria.postgresql.org; Wed, 07 Aug 2013 15:33:58 +0000 Received: from makus.postgresql.org ([2001:4800:7903:4::125]) by malur.postgresql.org with esmtp (Exim 4.80) (envelope-from ) id 1V75kL-0002xV-UG for pgsql-performance@postgresql.org; Wed, 07 Aug 2013 15:33:58 +0000 Received: from gmmr2.centrum.cz ([2a00:da80:1:502::2]) by makus.postgresql.org with esmtp (Exim 4.80) (envelope-from ) id 1V75kH-0005hH-Fk for pgsql-performance@postgresql.org; Wed, 07 Aug 2013 15:33:57 +0000 Received: from mail1007.cent (unknown [10.32.3.100]) by gmmr2.centrum.cz (Postfix) with ESMTP id B620A6000731; Wed, 7 Aug 2013 17:33:49 +0200 (CEST) Received: by mail1007.cent (Postfix, from userid 33) id AB02520045437; Wed, 7 Aug 2013 17:33:49 +0200 (CEST) To: =?utf-8?q?Igor_Neyman?= , =?utf-8?q?Pavel_Stehule?= Subject: =?utf-8?q?RE=3A_=5BPERFORM=5D_Re=3A_=5BPERFORM=5D_Sub=2Doptimal_plan_for_a_paginated_query_on_a_view_with_another_view_inside_of_it=2E?= Received: from 195.168.8.115 (X-Forwarded-For: 195.168.8.115) by mail1007.centrum.cz (centrum.cz multimail) with HTTP Date: Wed, 07 Aug 2013 17:33:49 +0200 From: Cc: =?utf-8?q?pgsql=2Dperformance=40postgresql=2Eorg?= References: <20130802154316.59167BB5@centrum.sk>, , <20130807144239.654353D3@centrum.sk>, , <20130807164250.26C21834@centrum.sk> In-Reply-To: X-Mailer: Centrum Email 5.3 X-Priority: 3 X-Original-From: slapo@centrum.sk MIME-Version: 1.0 Message-Id: <20130807173349.E2F843A7@centrum.sk> X-Maser: oho X-Pg-Spam-Score: -1.9 (-) Content-Type: multipart/alternative; boundary="_d32c_-------8a336e122026dd2f1a9d96b7587caaaf" List-Archive: List-Help: List-ID: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: X-Mailing-List: pgsql-performance Precedence: bulk Sender: pgsql-performance-owner@postgresql.org This is a multi-part message in MIME format. --_ca29_-------efe7cdaf3da2b8101a7ab5f96ca2ebd5 Content-Type: multipart/alternative; boundary="_d32c_-------8a336e122026dd2f1a9d96b7587caaaf" --_d32c_-------8a336e122026dd2f1a9d96b7587caaaf Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit I got: "Total runtime: 9.313 ms" in pgAdmin "Total runtime: 9.363 ms" in psql. But timing after the query finished was 912.842 ms in psql.   Cheers,   Peter Slapansky ______________________________________________________________ > Od: Igor Neyman > Komu: "slapo@centrum.sk" , Pavel Stehule > Dátum: 07.08.2013 16:48 > Predmet: RE: [PERFORM] Re: [PERFORM] Sub-optimal plan for a paginated query on a view with another view inside of it. > > CC: "pgsql-performance@postgresql.org" From: slapo@centrum.sk [mailto:slapo@centrum.sk] Sent: Wednesday, August 07, 2013 10:43 AM To: Igor Neyman; Pavel Stehule Cc: pgsql-performance@postgresql.org Subject: RE: [PERFORM] Re: [PERFORM] Sub-optimal plan for a paginated query on a view with another view inside of it. You're right, it does... but it's quite odd, because I re-ran the explain-analyze statement and got the same results. Still, the query now runs for about a second as mentioned before, so it's almost like something's missing from the explain, but I'm certain I copied it all.   I did this via pgadmin, but that shouldn't matter, should it?   Thank you,   Peter Slapansky ______________________________________________________________ _________________________________________________________ At very end of explain analyze output there should be a line: Total runtime: .... What do you get there? Regards, Igor Neyman --_d32c_-------8a336e122026dd2f1a9d96b7587caaaf Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: 8bit

I got:

"Total runtime: 9.313 ms" in pgAdmin

"Total runtime: 9.363 ms" in psql.

But timing after the query finished was 912.842 ms in psql.

 

Cheers,

 

Peter Slapansky

______________________________________________________________
> Od: Igor Neyman <ineyman@perceptron.com>
> Komu: "slapo@centrum.sk" <slapo@centrum.sk>, Pavel Stehule <pavel.stehule@gmail.com>
> Dátum: 07.08.2013 16:48
> Predmet: RE: [PERFORM] Re: [PERFORM] Sub-optimal plan for a paginated query on a view with another view inside of it.
>

> CC: "pgsql-performance@postgresql.org"



From: slapo@centrum.sk [mailto:slapo@centrum.sk]
Sent: Wednesday, August 07, 2013 10:43 AM
To: Igor Neyman; Pavel Stehule
Cc: pgsql-performance@postgresql.org
Subject: RE: [PERFORM] Re: [PERFORM] Sub-optimal plan for a paginated query on a view with another view inside of it.

You're right, it does... but it's quite odd, because I re-ran the explain-analyze statement and got the same results.
Still, the query now runs for about a second as mentioned before, so it's almost like something's missing from the explain, but I'm certain I copied it all.
 
I did this via pgadmin, but that shouldn't matter, should it?
 
Thank you,
 
Peter Slapansky
______________________________________________________________
_________________________________________________________

At very end of explain analyze output there should be a line:

Total runtime: ....

What do you get there?

Regards,
Igor Neyman

--_d32c_-------8a336e122026dd2f1a9d96b7587caaaf-- --_ca29_-------efe7cdaf3da2b8101a7ab5f96ca2ebd5--