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 1kwUOo-0005DS-R3 for pgsql-bugs@arkaria.postgresql.org; Mon, 04 Jan 2021 18:16:10 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1kwUOn-0006xW-O6 for pgsql-bugs@arkaria.postgresql.org; Mon, 04 Jan 2021 18:16:09 +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 1kwUOn-0006xN-I1 for pgsql-bugs@lists.postgresql.org; Mon, 04 Jan 2021 18:16:09 +0000 Received: from sss.pgh.pa.us ([66.207.139.130]) by makus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1kwUOi-00042y-DC for pgsql-bugs@lists.postgresql.org; Mon, 04 Jan 2021 18:16:08 +0000 Received: from sss1.sss.pgh.pa.us (localhost [127.0.0.1]) by sss.pgh.pa.us (8.15.2/8.15.2) with ESMTP id 104IFrCk3161685; Mon, 4 Jan 2021 13:15:54 -0500 From: Tom Lane To: mailtch@163.com cc: pgsql-bugs@lists.postgresql.org Subject: Re: BUG #16803: create a table only one text/varchar column, storage options toast_tuple_target doesn't work In-reply-to: <16803-0acffe06339b12be@postgresql.org> References: <16803-0acffe06339b12be@postgresql.org> Comments: In-reply-to PG Bug reporting form message dated "Mon, 04 Jan 2021 14:53:12 +0000" MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-ID: <3161683.1609784153.1@sss.pgh.pa.us> Date: Mon, 04 Jan 2021 13:15:53 -0500 Message-ID: <3161684.1609784153@sss.pgh.pa.us> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk PG Bug reporting form writes: > create a table only one text/varchar colume, storage options > toast_tuple_target doesn't work, see: The reason your first example isn't doing anything is that the tuples are shorter than TOAST_TUPLE_THRESHOLD, which is the threshold row length for applying the toasting code at all. The reloption doesn't affect that; it only changes the target length once we've gotten into the toaster. It's not real clear to me why whoever provided a knob for TOAST_TUPLE_TARGET didn't see fit to also provide one for TOAST_TUPLE_THRESHOLD, but I suppose that was a deliberate choice. The documentation is certainly clear enough that you can only adjust the target. regards, tom lane