Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1kmaK8-0000tm-Bf for pgsql-docs@arkaria.postgresql.org; Tue, 08 Dec 2020 10:34:24 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1kmaK7-0002U5-5i for pgsql-docs@arkaria.postgresql.org; Tue, 08 Dec 2020 10:34:23 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1kmaK6-0002Tu-RQ for pgsql-docs@lists.postgresql.org; Tue, 08 Dec 2020 10:34:22 +0000 Received: from mail-ej1-x62a.google.com ([2a00:1450:4864:20::62a]) by makus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.92) (envelope-from ) id 1kmaK3-0005uW-3G for pgsql-docs@lists.postgresql.org; Tue, 08 Dec 2020 10:34:21 +0000 Received: by mail-ej1-x62a.google.com with SMTP id g20so23931801ejb.1 for ; Tue, 08 Dec 2020 02:34:18 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cybertec-at.20150623.gappssmtp.com; s=20150623; h=message-id:subject:from:to:cc:date:in-reply-to:references :user-agent:mime-version:content-transfer-encoding; bh=DmcaWEY+CJX9uQfRT2DElCNqG6pkMChK0sU2zziwo94=; b=nBBmxSqkHjUAFl0tnoxDnbHrXkQhEU3J+0grnIkVe+mFlyj/EVVxpmIwmclvDYKmVX T56KTDSqKqxSxLKXEiBEPzK/pEnVzQzxuiMXbSb9YOYZhsgFqYGv5SQtED8E3D45e4dT tsu6kvlI2VTp/VTJSmFGzKoIZpx2EJAu/cetzn0CQyRb/ulSDE83WWrCF2fp5kP82+yZ IDqPZOvQeMxgFFlEU6I4dTPEgfjSUe/gvGij/Pe6HMNvasHWQ7TPjvB+l29FrmXS7sWh niy1Zzp4Vee52QcEY07NudhE5ha18jubUWMUSTS5E4Wwg5QiHYQlQNYCNWHebTTGHmhV BnGA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:message-id:subject:from:to:cc:date:in-reply-to :references:user-agent:mime-version:content-transfer-encoding; bh=DmcaWEY+CJX9uQfRT2DElCNqG6pkMChK0sU2zziwo94=; b=gai3JPeI+7SndOwGw6Y2kF/qVbBVTHAT1fXM8aSCrRhWP1JmBOxx7m9ZjMU4lCnVc5 ExvOmoj9XzpBQU3YZWz1vLam0aE9qMZhmnnqW5DfxkVntt1MXH3OaiLqjtvdD8m0RTyr r/EQFBTJTTfCnTRgHOzBhpRv769xEIP1Hn72vs32E+sAgx6pPm0RdAvvTLRkf+Q3spGI 3wPjiudJvaYlrBePhXM2tYcGhZzuG6lry3cgOnJrbKav+c+zyZfTvjy2UnLq8zTA5P9J fCrmcWwAkA3xOu+3OFQc7+GmpmD8jFp5Wne7f7+pS4kVMmKp+p0KOCSU5/8wgmZ0ugag jzOA== X-Gm-Message-State: AOAM532XEhoMAABy1iv6xJW1aherkY7VMlbZKOXbXXCykZM9IaFAbK69 hbI9m5zzZqI5ieCUuj+lSA2JxQ== X-Google-Smtp-Source: ABdhPJz+7c2Lb2G/xgSsoEmiYwnk++DJtL1thQ3Hyp1jkW7Rct1AjVoO0gom74m+kuXk2MuVfhm5Lw== X-Received: by 2002:a17:906:f1cc:: with SMTP id gx12mr21829526ejb.164.1607423657241; Tue, 08 Dec 2020 02:34:17 -0800 (PST) Received: from localhost.localdomain (62-46-249-52.adsl.highway.telekom.at. [62.46.249.52]) by smtp.gmail.com with ESMTPSA id r24sm9023769edc.21.2020.12.08.02.34.16 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 08 Dec 2020 02:34:16 -0800 (PST) Message-ID: <48125106de1a275b1e0c2d46b7c0a56a2b0675cb.camel@cybertec.at> Subject: Re: Mention invalid null byte sequence From: Laurenz Albe To: Tom Lane Cc: bugs-postgresql@antipoul.fr, pgsql-docs@lists.postgresql.org Date: Tue, 08 Dec 2020 11:34:15 +0100 In-Reply-To: <3153759.1607372842@sss.pgh.pa.us> References: <160720552914.710.16625261471128631268@wrigleys.postgresql.org> <0f0470f6d8c543793d2b71913cb230daea1aef3a.camel@cybertec.at> <3153759.1607372842@sss.pgh.pa.us> Content-Type: text/plain; charset="UTF-8" User-Agent: Evolution 3.36.5 (3.36.5-1.fc32) MIME-Version: 1.0 Content-Transfer-Encoding: 7bit List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk On Mon, 2020-12-07 at 15:27 -0500, Tom Lane wrote: > Laurenz Albe writes: > > On Sat, 2020-12-05 at 21:58 +0000, PG Doc comments form wrote: > > > The following documentation comment has been logged on the website: > > > Page: https://www.postgresql.org/docs/13/datatype-character.html > > > Description: > > > > > > So it should written in the character type that null byte are not accepted, > > > it would make like easier to migrate to PostgreSQL :) > > > > +1; how about the attached patch? > > I had thought that this was already documented, but after digging around > I can only find it mentioned in the contexts of saying that literal > strings and quoted identifiers can't contain \0. So yeah, we need to > improve that. > > I agree with the submitter that the place one would expect to read about > this is in datatype-character.html. So I'd propose the attached. > Maybe there's reason to repeat the info in charset.sgml, but it seems > like more of a datatype limitation than a character set issue. +1 on your patch. Yours, Laurenz Albe