> On Aug 1, 2018, at 10:20 AM, Daniel Verite <dan...@manitou-mail.org> wrote:
> 
>   /* Check header */
> -  if (!cstate->csv_mode && cstate->header_line)
> +  if (cstate->binary && cstate->header_line)
>     ereport(ERROR,
> -  (errcode(ERRCODE_FEATURE_NOT_SUPPORTED),
> -    errmsg("COPY HEADER available only in CSV mode")));
> +      (errcode(ERRCODE_SYNTAX_ERROR),
> +       errmsg("cannot specify HEADER in BINARY mode")));
> 
> Why should ERRCODE_FEATURE_NOT_SUPPORTED become ERRCODE_SYNTAX_ERROR?
> 

I agree; it should remain ERRCODE_FEATURE_NOT_SUPPORTED and I might also 
suggest the message read "COPY HEADER not available in BINARY mode", although 
I'm pretty agnostic on the latter.

Regards,
-Cynthia Shang

Reply via email to