Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.89) (envelope-from ) id 1gJzd5-0003zp-Tx for pgsql-general@arkaria.postgresql.org; Tue, 06 Nov 2018 11:34:44 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1gJzd4-0003C0-BZ for pgsql-general@arkaria.postgresql.org; Tue, 06 Nov 2018 11:34:42 +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.89) (envelope-from ) id 1gJzd3-0003Bs-Vr for pgsql-general@lists.postgresql.org; Tue, 06 Nov 2018 11:34:42 +0000 Received: from mail-qk1-x742.google.com ([2607:f8b0:4864:20::742]) by magus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1gJzcw-0003tM-AM for pgsql-general@lists.postgresql.org; Tue, 06 Nov 2018 11:34:41 +0000 Received: by mail-qk1-x742.google.com with SMTP id y16so16971576qki.7 for ; Tue, 06 Nov 2018 03:34:33 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=2ndquadrant-com.20150623.gappssmtp.com; s=20150623; h=date:from:to:cc:subject:message-id:mime-version:content-disposition :content-transfer-encoding:in-reply-to:user-agent; bh=Q2Z4TBtHppbxo37d98sjEEDgBZZas5ORUZDCTWodso4=; b=i2FjAvlCW0/sDX2vhbZcHHHI2rEMJBgnokErpNC1Ca6VwtgJWqxd6uOl4YQ5ak1IEf iBzDfVrlVnPC1uKJJFDoVGtMyQmDnMVA8rX1mbdDkzh68QRo6k2cO8v44dU8cTHFB+sc ret9NOZ1gIk2GQJrMctBC3wMZ2H9hrOK7nHZEWgO51hzq8UY2JCuIyMeCziBIh+iv3Ef AriVcR8u1jswUJM67yy+VlhZvuYTurgx+dMUYEoWNbQqzd2Q7AGWKVyQQzo0yb+DAIsx +WCtXabfV2Z7tx9BXy6Ygf0LutUN3orVu1Z/LDzvmS7UPF6mXXtzJP33SJzGohuD4i/o kbuw== 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:mime-version :content-disposition:content-transfer-encoding:in-reply-to :user-agent; bh=Q2Z4TBtHppbxo37d98sjEEDgBZZas5ORUZDCTWodso4=; b=n7NNR87ijwIx9p34nPgkudkfnhEJKoP0XTWDeJwkkdkoF1pa2koo6U1SWGqHc8Z+DH T4qtOaR/V6jy09UrMIztLaiyaSPH5SCVePjn7I4/+Y/g9UXNrILMoBIOvStuYd1SdpCt YLhkW4KXSiK4kN7BiAEGX75X81RknpPXuka/WYzQ2EX4NXPGmAkz/qyr7FGkmP/Tjhgp zjGJhxUNEssntEdLZcPep9XkN/10xPzj7MrNtEQMuKUZ05YHGafmU1CEiwWv+hNbgAph g29rSNBaM55aTP117cpLaV1JiTueAWZyiz8HRLdGHdFvPEp7/xGFaBlkU8KaFhzszpNE kwVQ== X-Gm-Message-State: AGRZ1gJV8Gym2pW2KyGsOUH/ZztYPZmfy1ql76k8WYeGImlJt5+REB7c YYsNeXkZii5/eArdfcPCwKL1S8JLVKE= X-Google-Smtp-Source: AJdET5ey512flvjPhWlYzPP4DJ76XiXJ/EzKtoX3MfIWFMzdRICoOd7gI3ZVOyoj/xGC9kqQwUXZvw== X-Received: by 2002:a37:6250:: with SMTP id w77mr23904588qkb.148.1541504072318; Tue, 06 Nov 2018 03:34:32 -0800 (PST) Received: from alvin.alvh.no-ip.org ([201.186.80.75]) by smtp.gmail.com with ESMTPSA id q62-v6sm16165359qkf.74.2018.11.06.03.34.31 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Tue, 06 Nov 2018 03:34:31 -0800 (PST) Received: by alvin.alvh.no-ip.org (Postfix, from userid 1000) id B410F5BE; Tue, 6 Nov 2018 08:34:29 -0300 (-03) Date: Tue, 6 Nov 2018 08:34:29 -0300 From: Alvaro Herrera To: Ron Cc: pgsql-general@lists.postgresql.org Subject: Re: CREATE OR REPLACE FUNCTION statement just sitting there Message-ID: <20181106113429.eckik5dtmspck4lz@alvherre.pgsql> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <2394ea86-6a5f-ddce-8929-a37376192eaf@gmail.com> User-Agent: NeoMutt/20180716 List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk On 2018-Nov-05, Ron wrote: > That (plus pg_locks)  is the heart of the "list all blocking queries" > statement I copied from https://wiki.postgresql.org/wiki/Lock_Monitoring. On that page there's a note about 9.6. Did you see the referenced commit https://git.postgresql.org/gitweb/?p=postgresql.git;a=commit;h=52f5d578d6c29bf254e93c69043b817d4047ca67 ? Maybe see about using the "pg_blocking_pids(int) returns int[]" function instead. -- Álvaro Herrera https://www.2ndQuadrant.com/ PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services