Re: Add support for DEFAULT specification in COPY FROM
Andrew Dunstan <andrew@dunslane.net>
From: Andrew Dunstan <andrew@dunslane.net>
To: Alexander Lakhin <exclusion@gmail.com>,
Israel Barth Rubio <barthisrael@gmail.com>, Zhihong Yu <zyu@yugabyte.com>
Cc: pgsql-hackers@lists.postgresql.org
Date: 2023-03-15T21:21:49Z
Lists: pgsql-hackers
On 2023-03-15 We 13:00, Alexander Lakhin wrote: > Hello, > 13.03.2023 17:15, Andrew Dunstan wrote: >> >> On 2022-12-02 Fr 09:11, Israel Barth Rubio wrote: >>> Hello all, >>> >>> I'm submitting a new version of the patch. Instead of changing >>> signature >>> of several functions in order to use the defaults parameter, it is >>> now storing >>> that in the cstate structure, which is already passed to all >>> functions that >>> were previously modified. >>> >> >> Thanks, committed. > > Please look at the query: > create table t (f1 int); > copy t from stdin with (format csv, default '\D'); > 1,\D > > that invokes an assertion failure after 9f8377f7a: > Core was generated by `postgres: law regression [local] > COPY '. > Program terminated with signal SIGABRT, Aborted. > > Fix pushed, thanks for the report. cheers andrew -- Andrew Dunstan EDB:https://www.enterprisedb.com
Commits
-
Add a DEFAULT option to COPY FROM
- 9f8377f7a279 16.0 landed