From: | 曾文旌(义从) <wenjing(dot)zwj(at)alibaba-inc(dot)com> |
---|---|
To: | Prabhat Sahu <prabhat(dot)sahu(at)enterprisedb(dot)com> |
Cc: | "tushar" <tushar(dot)ahuja(at)enterprisedb(dot)com>, "Pavel Stehule" <pavel(dot)stehule(at)gmail(dot)com>, "Robert Haas" <robertmhaas(at)gmail(dot)com>, "Tomas Vondra" <tomas(dot)vondra(at)2ndquadrant(dot)com>, "Konstantin Knizhnik" <k(dot)knizhnik(at)postgrespro(dot)ru>, "PostgreSQL Hackers" <pgsql-hackers(at)postgresql(dot)org>, 蔡松露(子嘉) <zijia(at)taobao(dot)com>, Cai, Le <le(dot)cai(at)alibaba-inc(dot)com>, 萧少聪(铁庵) <shaocong(dot)xsc(at)alibaba-inc(dot)com> |
Subject: | Re: [Proposal] Global temporary tables |
Date: | 2020-03-06 07:00:21 |
Message-ID: | E1979F6A-456C-41BC-AE7E-5196CED8D0DC@alibaba-inc.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
> 2020年3月4日 下午3:49,Prabhat Sahu <prabhat(dot)sahu(at)enterprisedb(dot)com> 写道:
>
> On Tue, Mar 3, 2020 at 2:11 PM 曾文旌(义从) <wenjing(dot)zwj(at)alibaba-inc(dot)com <mailto:wenjing(dot)zwj(at)alibaba-inc(dot)com>> wrote:
>
>
>
> I fixed in global_temporary_table_v16-pg13.patch.
>
> Thank you Wenjing for the patch.
> Now we are getting corruption with GTT with below scenario.
>
> postgres=# CREATE GLOBAL TEMPORARY TABLE gtt1(c1 bigint, c2 bigserial) on commit delete rows;
> CREATE TABLE
> postgres=# CREATE GLOBAL TEMPORARY TABLE gtt2(c1 bigint, c2 bigserial) on commit preserve rows;
> CREATE TABLE
> postgres=# \q
>
> [edb(at)localhost bin]$ echo "1
> > 2
> > 3
> > "> t.dat
>
> [edb(at)localhost bin]$ ./psql postgres
> psql (13devel)
> Type "help" for help.
>
> postgres=# \copy gtt1(c1) from 't.dat' with csv;
> ERROR: could not read block 0 in file "base/13585/t3_16384": read only 0 of 8192 bytes
> CONTEXT: COPY gtt1, line 1: "1"
>
> postgres=# \copy gtt2(c1) from 't.dat' with csv;
> ERROR: could not read block 0 in file "base/13585/t3_16390": read only 0 of 8192 bytes
> CONTEXT: COPY gtt2, line 1: "1"
>
> NOTE: We end with such corruption for "bigserial/smallserial/serial" datatype columns.
Thanks for review.
I fixed this issue in global_temporary_table_v17-pg13.patch
Wenjing
>
> --
> With Regards,
> Prabhat Kumar Sahu
> EnterpriseDB: http://www.enterprisedb.com <http://www.enterprisedb.com/>
From | Date | Subject | |
---|---|---|---|
Next Message | 曾文旌 (义从) | 2020-03-06 07:05:30 | Re: [Proposal] Global temporary tables |
Previous Message | Masahiko Sawada | 2020-03-06 06:31:00 | Re: Internal key management system |