On 2019/04/04 16:52, Peter Eisentraut wrote:
> On 2019-04-02 20:54, Erik Rijkers wrote:
>> attached is run_ft.sh  which creates a text file:  /tmp/pg_head.txt
>> then sets it up as a foreign table, and adds a generated column.
>>
>> Then selects a succesful select, followed by a error-producing select.
> 
> I have committed a fix for this.

+-- generated column tests
+CREATE FOREIGN TABLE gft1 (a int, b text, c text GENERATED ALWAYS AS
('foo') STORED) SERVER file_server
+OPTIONS (format 'csv', filename '@abs_srcdir@/data/list1.csv', delimiter
',');
+SELECT a, c FROM gft1;
+ a |   c
+---+--------
+ 1 | _null_
+ 1 | _null_

Hmm, I'm afraid we might get bug reports if we go with this.  Why is it OK
to get null in this case when a user explicitly asked for 'foo'?

Thanks,
Amit



Reply via email to