Tomas Vondra wrote: > On 11/30/2017 04:20 PM, Ildus Kurbangaliev wrote:
> > CREATE COMPRESSION METHOD ts1 FOR tsvector HANDLER > > tsvector_compression_handler; > > Understood. Good to know you've considered it, and I agree it doesn't > need to be there from the start (which makes the patch simpler). Just passing by, but wouldn't this fit in the ACCESS METHOD group of commands? So this could be simplified down to CREATE ACCESS METHOD ts1 TYPE COMPRESSION we have that for indexes and there are patches flying for heap storage, sequences, etc. I think that's simpler than trying to invent all new commands here. Then (in a future patch) you can use ALTER TYPE to define compression for that type, or even add a column-level option to reference a specific compression method. -- Álvaro Herrera https://www.2ndQuadrant.com/ PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services