Re: [PATCHES] [HACKERS] Unworkable column delimiter characters for COPY

2007-12-28 Thread Andrew Dunstan
Tom Lane wrote: I see that we disallow the CSV quote character from appearing in the null_print string, but not the escape character. Is this correct/sensible? Yes, because: . nulls are never quoted . fields containing the quote char must be quoted . the escape char is only magical inside

Re: [PATCHES] [HACKERS] Unworkable column delimiter characters for COPY

2007-12-27 Thread Andrew Dunstan
Tom Lane wrote: Andrew Dunstan [EMAIL PROTECTED] writes: Tom Lane wrote: I think at minimum we need to forbid b, f, n, r, t, v, which are the control character representations currently recognized by COPY. But I'm tempted to make it reject all 26 lower-case ASCII letters, as a form

Re: [PATCHES] [HACKERS] Unworkable column delimiter characters for COPY

2007-12-27 Thread Tom Lane
Andrew Dunstan [EMAIL PROTECTED] writes: Tom Lane wrote: It seems we ought to forbid delimiter from matching CSV quote or escape characters. I'll let you clean up that case though... This should do the trick - I'll apply it tomorrow. A couple thoughts: * This test needs to appear further