Re: explain format json, unit for serialize and memory are different.

From: David Rowley <dgrowleyml(at)gmail(dot)com>
To: jian he <jian(dot)universality(at)gmail(dot)com>
Cc: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, Michael Paquier <michael(at)paquier(dot)xyz>, Daniel Gustafsson <daniel(at)yesql(dot)se>, PostgreSQL Hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: explain format json, unit for serialize and memory are different.
Date: 2024-05-15 04:44:32
Message-ID: CAApHDvrrJvJR8KZiqZcmLGdq4pPYA6GC8pwW3UM_KCtx1w7WVw@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Wed, 15 May 2024 at 15:40, jian he <jian(dot)universality(at)gmail(dot)com> wrote:
> I am looking for an example where this information under json key
> "Serialization" is not zero.
> So far I have tried:

Something that requires detoasting.

> create table s(a text);
> insert into s select repeat('a', 1024) from generate_series(1,1024);
> explain (format json, analyze, wal, buffers, memory, serialize, timing
> off) select * from s;

Something bigger than 1024 bytes or use SET STORAGE EXTERNAL or EXTENDED.

create table s(a text);
insert into s select repeat('a', 1024*1024) from generate_series(1,10);
explain (format text, analyze, buffers, serialize, timing off) select * from s;

Serialization: output=10241kB format=text
Buffers: shared hit=36

David

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Tatsuo Ishii 2024-05-15 04:52:42 Re: CFbot does not recognize patch contents
Previous Message Michael Paquier 2024-05-15 04:27:10 Re: Underscore in positional parameters?