Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.84_2) (envelope-from ) id 1e9ygG-0007qx-K3 for pgsql-general@arkaria.postgresql.org; Wed, 01 Nov 2017 19:28:04 +0000 Received: from localhost ([127.0.0.1] helo=postgresql.org) by malur.postgresql.org with smtp (Exim 4.84_2) (envelope-from ) id 1e9ygF-0000pW-EO for pgsql-general@arkaria.postgresql.org; Wed, 01 Nov 2017 19:28:03 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1e9ydp-0004pY-NE for pgsql-general@postgresql.org; Wed, 01 Nov 2017 19:25:33 +0000 Received: from mail-io0-x22f.google.com ([2607:f8b0:4001:c06::22f]) by magus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.84_2) (envelope-from ) id 1e9ydk-0002E1-Uf for pgsql-general@postgresql.org; Wed, 01 Nov 2017 19:25:32 +0000 Received: by mail-io0-x22f.google.com with SMTP id 134so8528992ioo.0 for ; Wed, 01 Nov 2017 12:25:28 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=telsasoft-com.20150623.gappssmtp.com; s=20150623; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to:user-agent; bh=QfWqotATcqpwiBu541waHXS2i6tbtsbeBDmzts/1MRA=; b=KmzDeT0p4ZDcYlZi814aXQWxHP6IbzwtwXnEA5HkWxk8keZlFbQ3KJpfm89Hvvgp5i DWU7ZidBH8ugN9A0YwHqNYsWitFaEzBt3Xl+jTGwV9plQ0mEPSMdpDOV0UQG9ZEDwuiQ XEn2MCbR0bU5nxck5cr+gLHn+k3llKPIl3oukRb1ycGbnxQwFjrEWE+upUKXFRJ3en4k bbMt6dyJ16dlRTD7cgsUMF2D65vfR+f56IKCw2latYGzTl2qiKlav5b1vK5hjTq+1OB4 DcJeWCaxWdNgdKosBrsmn0NTnxOQlL0afbqyWtUmZcdZnn1HTC6DOaQn1WMOr6AbhHJI IrVA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to:user-agent; bh=QfWqotATcqpwiBu541waHXS2i6tbtsbeBDmzts/1MRA=; b=RaoLxWhaT/Xt9PdvCtfJRBmG9ih7Yzut5b+AAZipy0kUH9drEglSmmmwbRNxXT7+8m V3q5whpjkD4F8WTth49n6fUI0QxroNoAaUBDcxI1t+mPcEuoT015YnneuGWb71OFpV0R e1ahiQBOq6nsMAOk5De5ClPZa43dz4XO+CbCcaUd8WZS7JYYWGQy/wyGpL5gAeLeoB7y QrJyiE1al6y5QLJ4WpFe3Py3umhJj951wVkwhZBU4MP3pHVcrGr0kiWuKTKED6amlTUj fJ9EIb2hlMDbiOHF2MUAKpv3mn44bS4HndL2ESO8AENNpo75yp8cBOmWeLQhPt5Wt58e BR6Q== X-Gm-Message-State: AMCzsaXXW603D9Fy5SvnEzJG+xmdJIhB/vQhuoLrB7QULPD28+6LgUkQ yowZ26O3CzrdnIKbwU18VbjWOQ== X-Google-Smtp-Source: ABhQp+R0VmJQSYFeeK+e3IsJiCz85pVE0eubKY0pcfevL6uigJXPWB/fnBQZru0zYywlTHLUb0nOyA== X-Received: by 10.36.25.12 with SMTP id b12mr2022326itb.1.1509564327180; Wed, 01 Nov 2017 12:25:27 -0700 (PDT) Received: from pryzbyj (charmander.telsasoft.com. [50.244.222.1]) by smtp.gmail.com with ESMTPSA id k66sm733588ita.6.2017.11.01.12.25.26 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 01 Nov 2017 12:25:26 -0700 (PDT) Received: by pryzbyj (Postfix, from userid 1000) id C6C56801850; Wed, 1 Nov 2017 14:25:25 -0500 (CDT) Date: Wed, 1 Nov 2017 14:25:25 -0500 From: Justin Pryzby To: "David G. Johnston" Cc: Scott Marlowe , "pgsql-general@postgresql.org" Subject: Re: explain analyze output: 0 rows, 1M loops Message-ID: <20171101192525.GR21735@telsasoft.com> References: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.23 (2014-03-12) List-Archive: List-Help: List-ID: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: X-Mailing-List: pgsql-general Precedence: bulk Sender: pgsql-general-owner@postgresql.org On Wed, Nov 01, 2017 at 12:19:21PM -0700, David G. Johnston wrote: > On Wed, Nov 1, 2017 at 11:59 AM, Scott Marlowe > wrote: > > > So some of my output from an explain analyze here has a line that says > > this: > > > > ex Scan using warranty_order_item_warranty_order_id_idx on > > warranty_order_item woi_1 (cost=0.57..277.53 rows=6 width=137) (actual > > time=0.110..0.111 rows=0 loops=1,010,844) > > > > Not my strong suit but, I'm pretty sure that reads: "The index was queried > 1M+ times and none of those inqueries resulted in a record being found". > IIUC I'd be wondering why some form of hash join wasn't used... Except that: https://www.postgresql.org/docs/current/static/using-explain.html "... the loops value reports the total number of executions of the node, and the actual time and ROWS VALUES SHOWN ARE AVERAGES PER-EXECUTION." Justin -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-general