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 1hhtYe-00061S-Nt for pgsql-docs@arkaria.postgresql.org; Mon, 01 Jul 2019 10:29:12 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1hhtYd-0006CO-HA for pgsql-docs@arkaria.postgresql.org; Mon, 01 Jul 2019 10:29:11 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1hhtYd-0006CH-2c for pgsql-docs@lists.postgresql.org; Mon, 01 Jul 2019 10:29:11 +0000 Received: from smtp.outgoing.loopia.se ([194.9.95.112]) by makus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1hhtYV-0003lP-NV for pgsql-docs@lists.postgresql.org; Mon, 01 Jul 2019 10:29:09 +0000 Received: from s554.loopia.se (localhost [127.0.0.1]) by s554.loopia.se (Postfix) with ESMTP id C03DD1F16543 for ; Mon, 1 Jul 2019 12:28:59 +0200 (CEST) Received: from s630.loopia.se (unknown [172.21.200.107]) by s554.loopia.se (Postfix) with ESMTP id A19C07A61D8; Mon, 1 Jul 2019 12:28:59 +0200 (CEST) Received: from s471.loopia.se (unknown [172.21.200.35]) by s630.loopia.se (Postfix) with ESMTP id 83107C663E8; Mon, 1 Jul 2019 12:28:59 +0200 (CEST) X-Virus-Scanned: amavisd-new at amavis.loopia.se X-Spam-Flag: NO X-Spam-Score: -1 X-Spam-Level: X-Spam-Status: No, score=-1 tagged_above=-999 required=6.2 tests=[ALL_TRUSTED=-1] autolearn=disabled Received: from s645.loopia.se ([172.22.191.5]) by s471.loopia.se (s471.loopia.se [172.22.190.11]) (amavisd-new, port 10024) with LMTP id hxES0Mx8Fsc6; Mon, 1 Jul 2019 12:28:58 +0200 (CEST) X-Loopia-Auth: user X-Loopia-User: daniel@yesql.se X-Loopia-Originating-IP: 85.228.38.16 Received: from [192.168.1.69] (c-1026e455.027-294-73746f71.bbcust.telenor.se [85.228.38.16]) (Authenticated sender: daniel@yesql.se) by s645.loopia.se (Postfix) with ESMTPSA id 6EF9913BF399; Mon, 1 Jul 2019 12:28:58 +0200 (CEST) Content-Type: text/plain; charset=utf-8 Mime-Version: 1.0 (Mac OS X Mail 11.5 \(3445.9.1\)) Subject: Re: Non working example From: Daniel Gustafsson In-Reply-To: Date: Mon, 1 Jul 2019 12:28:56 +0200 Cc: pgsql-docs@lists.postgresql.org Content-Transfer-Encoding: quoted-printable Message-Id: <25D2F3EB-FEA2-41FB-8B3B-2AC6249C0658@yesql.se> References: <156180512744.7504.7429434193941404768@wrigleys.postgresql.org> To: Maarten van Gijssel X-Mailer: Apple Mail (2.3445.9.1) List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk > On 1 Jul 2019, at 12:19, Maarten van Gijssel = wrote: >=20 > After I posted the question, I realised my mistake =F0=9F=98=85. I was = using the pg gem in Ruby to run the SQL "SELECT encode('123\000\001', = 'base64')", the double quotes ensure the `\0` will be interpreted as a = null byte hence throwing the error. Aha, there we go. > Sorry, my mistake! No worries at all. cheers ./daniel=