Re: [feature]COPY FROM enable FORCE_NULL/FORCE_NOT_NULL on all columns - Mailing list pgsql-hackers

From Zhang Mingli
Subject Re: [feature]COPY FROM enable FORCE_NULL/FORCE_NOT_NULL on all columns
Date
Msg-id fd80e63a-9adb-4d42-a197-c3b8beda8d16@Spark
Whole thread Raw
In response to Re: [feature]COPY FROM enable FORCE_NULL/FORCE_NOT_NULL on all columns  (Damir Belyalov <dam.bel07@gmail.com>)
Responses Re: [feature]COPY FROM enable FORCE_NULL/FORCE_NOT_NULL on all columns
List pgsql-hackers
HI, 

Regards,
Zhang Mingli
On Jul 7, 2023, 18:00 +0800, Damir Belyalov <dam.bel07@gmail.com>, wrote:

The patch does not work for the current version of postgres, it needs to be updated.
I tested your patch. Everything looks simple and works well.

There is a suggestion to simplify the code: instead of using

if (cstate->opts.force_notnull_all)
{
int i;
for(i = 0; i < num_phys_attrs; i++)
cstate->opt.force_notnull_flags[i] = true;
}

Thanks very much for review. 

Nice suggestion, patch rebased and updated.

Attachment

pgsql-hackers by date:

Previous
From: Paul A Jungwirth
Date:
Subject: Re: Exclusion constraints on partitioned tables
Next
From: Amit Kapila
Date:
Subject: Re: Initial Schema Sync for Logical Replication