> I would agree that this is a bug because we are failing to detect
> what's actually a redundant option here as the first option still
> causes the flag to be set to false, but that's not something worth a
> back-patch IMO. What we are looking here is something similar
> to what is done with "format", where we track if the option has been
> specified with format_specified. The same is actually true with the
> "freeze" option here, and it is true that we tend to prefer error-ing
> in such cases while there are exceptions like EXPLAIN. I think that
> it would be nicer to be at least consistent with the behavior that
> each command has chosen, and COPY is now a mixed bag.
Here’s a new version of the patches that report an error when the options are set multiple time.
Regards,
Rémi