force_not_null option support for file_fdw

From: Shigeru Hanada <shigeru(dot)hanada(at)gmail(dot)com>
To: PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: force_not_null option support for file_fdw
Date: 2011-08-08 07:14:26
Message-ID: 4E3F8CD2.9040403@gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Hi,

I propose to support force_not_null option for file_fdw too.

In 9.1 development cycle, file_fdw had been implemented with exported
COPY FROM routines, but only force_not_null option has not been 
supported yet.

Originally, in COPY FROM, force_not_null is specified as a list of
column which is not matched against null-string. Now per-column FDW
option is available, so I implemented force_not_null options as boolean
value for each column to avoid parsing column list in file_fdw.

True means that the column is not matched against null-string, and it's
equivalent to specify the column's name in force_not_null option of COPY
FROM. Default value is false.

The patch includes changes for code, document and regression tests. Any
comments/questions are welcome.

Regards,
--
Shigeru Hanada

Attachment Content-Type Size
force_not_null_v2.patch text/plain 12.0 KB

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Alex Hunsaker 2011-08-08 07:23:08 Re: plperl crash with Debian 6 (64 bit), pl/perlu, libwww and https
Previous Message Kohei KaiGai 2011-08-08 07:12:20 Re: [RFC] Common object property boards