Re: TOAST table created for partitioned tables

2018-03-22 Thread Amit Langote
On 2018/03/23 2:51, Robert Haas wrote: > On Wed, Jan 17, 2018 at 1:03 AM, Amit Langote wrote: >> On Wed, Jan 17, 2018 at 1:51 PM, Michael Paquier >> wrote: >>> On Tue, Jan 16, 2018 at 11:38:58PM -0500, Tom Lane wrote: Yeah, pg_upgrade already has to cope with cases where the newer version >>

Re: TOAST table created for partitioned tables

2018-03-22 Thread Robert Haas
On Wed, Jan 17, 2018 at 1:03 AM, Amit Langote wrote: > On Wed, Jan 17, 2018 at 1:51 PM, Michael Paquier > wrote: >> On Tue, Jan 16, 2018 at 11:38:58PM -0500, Tom Lane wrote: >>> Yeah, pg_upgrade already has to cope with cases where the newer version >>> thinks a table needs a toast table when the

Re: TOAST table created for partitioned tables

2018-01-16 Thread Amit Langote
On Wed, Jan 17, 2018 at 1:51 PM, Michael Paquier wrote: > On Tue, Jan 16, 2018 at 11:38:58PM -0500, Tom Lane wrote: >> Yeah, pg_upgrade already has to cope with cases where the newer version >> thinks a table needs a toast table when the older version didn't, or >> vice versa. This looks like it

Re: TOAST table created for partitioned tables

2018-01-16 Thread Michael Paquier
On Tue, Jan 16, 2018 at 11:38:58PM -0500, Tom Lane wrote: > Yeah, pg_upgrade already has to cope with cases where the newer version > thinks a table needs a toast table when the older version didn't, or > vice versa. This looks like it ought to fall into that category. > Not that testing it wouldn

Re: TOAST table created for partitioned tables

2018-01-16 Thread Tom Lane
Amit Langote writes: > On Wed, Jan 17, 2018 at 5:32 AM, Robert Haas wrote: >> Aargh. Will apply this patch break pg_upgrade from v10? > AFAICS, it doesn't. Partitioned tables that used to have a TOAST > table in v10 cluster will continue to have it after upgrading. > Whereas, any partitioned t

Re: TOAST table created for partitioned tables

2018-01-16 Thread Amit Langote
On Wed, Jan 17, 2018 at 5:32 AM, Robert Haas wrote: > On Tue, Jan 16, 2018 at 5:13 AM, Amit Langote > wrote: >> I used to think that $subject didn't happen, but it actually does and ends >> up consuming a fixed 8192 bytes on the disk. >> >> create table p (a int[]) partition by list (a); >> CREAT

Re: TOAST table created for partitioned tables

2018-01-16 Thread Robert Haas
On Tue, Jan 16, 2018 at 5:13 AM, Amit Langote wrote: > I used to think that $subject didn't happen, but it actually does and ends > up consuming a fixed 8192 bytes on the disk. > > create table p (a int[]) partition by list (a); > CREATE TABLE > > select pg_table_size('p'); > pg_table_size >