Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.84_2) (envelope-from ) id 1eONcu-0006F4-Hj for pgsql-hackers@arkaria.postgresql.org; Mon, 11 Dec 2017 12:56:09 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.84_2) (envelope-from ) id 1eONct-0006IE-Qr for pgsql-hackers@arkaria.postgresql.org; Mon, 11 Dec 2017 12:56:07 +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.84_2) (envelope-from ) id 1eONct-0006I3-CO for pgsql-hackers@lists.postgresql.org; Mon, 11 Dec 2017 12:56:07 +0000 Received: from mail.postgrespro.ru ([93.174.131.138]) by magus.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1eONcm-0003od-PV for pgsql-hackers@postgresql.org; Mon, 11 Dec 2017 12:56:06 +0000 Received: from localhost (localhost [127.0.0.1]) by mail.postgrespro.ru (Postfix) with ESMTP id 2BFC921C1E5F; Mon, 11 Dec 2017 15:55:58 +0300 (MSK) X-Virus-Scanned: Debian amavisd-new at postgrespro.ru Received: from localhost.localdomain (unknown [31.173.148.242]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mail.postgrespro.ru (Postfix) with ESMTPSA id 9737921C1756; Mon, 11 Dec 2017 15:55:57 +0300 (MSK) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=postgrespro.ru; s=mail; t=1512996957; bh=ukDkDR0rna2CcULFXOu721fGfG+Te/KWMpBedm4JnEs=; h=Date:From:To:Cc:Subject:In-Reply-To:References; b=V55zMvxk+EwHqyWkGtJK8Z0x8rvBThCH+MaM5Q0Y5XAkby3p1aS/NF4qllwWApVLR cvKCIAlsQyKkXjEz9vqSgNsVCOpGlJ3dZF5Y2vpMJvwqHeEkCcmIK7C8Zi4RwaQu20 aHP31egKPFYudJ4aP3xO/0eFoBf4iP9hQ0DZcXaA= Date: Mon, 11 Dec 2017 15:55:55 +0300 From: Ildus Kurbangaliev To: Robert Haas Cc: Tomas Vondra , Alvaro Herrera , =?UTF-8?B?0JXQstCz0LXQvdC40Lkg0KjQuNGI0Lo=?= =?UTF-8?B?0LjQvQ==?= , Andres Freund , Oleg Bartunov , Craig Ringer , Peter Eisentraut , PostgreSQL Hackers Subject: Re: [HACKERS] Custom compression methods Message-ID: <20171211155555.05ddd2fc@postgrespro.ru> In-Reply-To: References: <20171201194859.le5hvnnrjzhxhm2t@alvherre.pgsql> <20171206180716.75ba9ba9@postgrespro.ru> X-Mailer: Claws Mail 3.15.1-dirty (GTK+ 2.24.31; x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk On Fri, 8 Dec 2017 15:12:42 -0500 Robert Haas wrote: > > Maybe a better idea is ALTER COLUMN SET COMPRESSION x1, x2, x3 ... > meaning that x1 is the default for new tuples but x2, x3, etc. are > still allowed if present. If you issue a command that only adds > things to the list, no table rewrite happens, but if you remove > anything, then it does. > I like this idea, but maybe it should be something like ALTER COLUMN SET COMPRESSION x1 [ PRESERVE x2, x3 ]? 'PRESERVE' is already used in syntax and this syntax will show better which one is current and which ones should be kept. -- ---- Regards, Ildus Kurbangaliev