Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1idLRp-000296-3m for pgsql-hackers@arkaria.postgresql.org; Fri, 06 Dec 2019 21:47:37 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1idLRn-0001EK-Tz for pgsql-hackers@arkaria.postgresql.org; Fri, 06 Dec 2019 21:47:35 +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_SHA1:256) (Exim 4.89) (envelope-from ) id 1idLRn-0001EC-Kc for pgsql-hackers@lists.postgresql.org; Fri, 06 Dec 2019 21:47:35 +0000 Received: from mail-ua1-x944.google.com ([2607:f8b0:4864:20::944]) by magus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1idLRk-0004pX-Gq for pgsql-hackers@postgresql.org; Fri, 06 Dec 2019 21:47:35 +0000 Received: by mail-ua1-x944.google.com with SMTP id r13so3472389uan.6 for ; Fri, 06 Dec 2019 13:47:32 -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=tsFhoYmvAsNPwXPw3Dco+65UVYWrHwE5SQbbgtEElvE=; b=Pbsm+NOvzIH+vaVWG6VUtgVkrwRl9HQQxdanTrTULmNRuHVZLCaNJ/6l5/he9g8Lid 003Bta60o8Ts1WpYJ+37bWL3PYO0fefFkmykfQ7wAaysg82YKTi78OlBvh9SSPgmwQxW JpXDy5+nd3WabZZ4SrQLgVZNZUiT0ggofwAQUYmARL8nGF2P2JxhFPHTAFTg9BwUJPrv dOwHRFYe9hv2NyfZP8hAGnHDt8gCSRwSG79BdKJMR/AHEL9d7ztiFHe7+rg/znPyKcOW qSfu+i9bOi4XwX0MlUYFNGsoEMAVlwNGlydKm0JCbcKPI1oYsI7Lba8CqzDy0ZFQFUlH AdYg== 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=tsFhoYmvAsNPwXPw3Dco+65UVYWrHwE5SQbbgtEElvE=; b=NzQNapFR0Si/3/oS1P9odczPDuKExUDFBddFun+pe69XvxeMc/TYuZu6GXfN6u931k jLZNDU9/F+8IRbw2ytn5RO13+e1nEo4gI8qtARPHPItAEGDRVJ5FSyd5ntR4SoBdG/TG iJDzj0+zWBnwRlZotFPn87ZFdKcy3YZRoZ6hPVq0QHf+afszgaYwgjRxiBWXp8IyQxn6 dbe0H7/alML29MW1pi5QFdJhL8TiWWMxUfWVDjmufXELY2og/Y20a9SnWHachgnWsFV/ QyODkNpeczH0KkB3yS8mRodAKbvQEYYdecU2z9eX8S4ODAgQHgl9VJ2SoX/+MvNGKRD6 oOPA== X-Gm-Message-State: APjAAAWZTiV911koNDcV2sFHaZzXFybJ9VXTn7laNU5xwWbOwKvh18e/ Io6acLrU1tFX2Kj26VOrvUr8/w== X-Google-Smtp-Source: APXvYqxyaKe7cQ/FY9ScGDLV2PLgGJmP6kzcOhlm4o4hEeE/18N2EikZxil1VBKVZw+jIVjlumZnLA== X-Received: by 2002:ab0:2315:: with SMTP id a21mr14552646uao.132.1575668850653; Fri, 06 Dec 2019 13:47:30 -0800 (PST) Received: from nimloth.alvh.no-ip.org ([190.121.29.3]) by smtp.gmail.com with ESMTPSA id g2sm6640961vsg.27.2019.12.06.13.47.30 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 06 Dec 2019 13:47:30 -0800 (PST) Received: by nimloth.alvh.no-ip.org (Postfix, from userid 1000) id C7B5030081C; Fri, 6 Dec 2019 18:47:26 -0300 (-03) Date: Fri, 6 Dec 2019 18:47:26 -0300 From: Alvaro Herrera To: Pavel Stehule Cc: Tom Lane , Andres Freund , Alexey Bashtanov , Peter Eisentraut , PostgreSQL Hackers Subject: Re: log bind parameter values on error Message-ID: <20191206214726.GA4669@alvherre.pgsql> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: User-Agent: Mutt/1.10.1 (2018-07-13) List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk On 2019-Dec-06, Pavel Stehule wrote: > pá 6. 12. 2019 v 18:57 odesílatel Alvaro Herrera > napsal: > > (It seems a bit weird that if I assign NULL to :two pgbench stores the > > empty string, instead of the NULL that I get as in the above which is > > what happens when the variable is not defined at all. That's probably a > > bug in \gset ...) > > psql session variables cannot to hold NULL I also just learned that the :foo expansion in pgbench behaves crazily when in normal query mode, particularly re. quotes in variables. -- Álvaro Herrera https://www.2ndQuadrant.com/ PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services