Hi
On Thu, 27 Nov 2025 at 20:38, Sugamoto Shinya <[email protected]> wrote:
>
>
>
> Regarding the option `convert_selectively`, what do you think about this?
> Still it seems to me that this option is accessible from SQL interfaces. But 
> for now
> I just removed the comment changes from my v2 patch and would like to discuss
> this with you here or in another thread.
>
> Regards,
>

It is worse than that - user can  lose his data by using
convert_selectively from SQL:

```
db1=# COPY conv_test FROM STDIN (
    FORMAT csv,
    convert_selectively (a)
);
Enter data to be copied followed by a newline.
End with a backslash and a period on a line by itself, or an EOF signal.
>> 2,2,dsd
>> \.
COPY 1
db1=# table conv_test
db1-# ;
 a | b | c
---+---+---
 2 |   |
(1 row)

```


So, this option should be rejected when manually specified. Looks like
we can do ereport() directly in parser, when reading option name

-- 
Best regards,
Kirill Reshke


Reply via email to