Re: [PATCHES] allow CSV quote in NULL

From: Andrew Dunstan <andrew(at)dunslane(dot)net>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: Stephen Frost <sfrost(at)snowman(dot)net>, Gregory Stark <stark(at)enterprisedb(dot)com>, PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: [PATCHES] allow CSV quote in NULL
Date: 2007-07-31 16:55:35
Message-ID: 46AF6987.1080508@dunslane.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers pgsql-patches

Tom Lane wrote:
> Stephen Frost <sfrost(at)snowman(dot)net> writes:
>
>> Other, unrelated, options being or not being there doesn't really have
>> any bearing on this though. I'm not inventing new syntax here. I'm
>> just removing a restriction on what the user can do that doesn't need
>> to exist.
>>
>
> I don't think you're "just removing a restriction". What you're doing
> is exposing a whole lot of strange and arguably broken corner cases.
> If we accept this patch I think we'll be fielding bug reports as a
> result for years to come. I *especially* dislike the part about
> allowing the delimiter character in the null string --- that will allow
> people to complain about the order in which decisions are made.
>
>
>

Yeah, if you allow the delimiter in the null string, what do you do if
it's not quoted? I can't imagine what the real world case for that could
possibly be.

Even if there's an arguable case for allowing the quote char in a null
string (and as I indicated upthread I really think the problem being
addressed here could be solved in a far better fashion) there is surely
no good case for allowing the delimiter. Oh, and if we did allow the
quote char we should surely only allow it on input - just because other
programs produce absurd output there is not reason we should.

cheers

andrew

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Stefan Kaltenbrunner 2007-07-31 17:00:03 Re: Reducing Transaction Start/End Contention
Previous Message Simon Riggs 2007-07-31 16:55:33 Re: stats_block_level

Browse pgsql-patches by date

  From Date Subject
Next Message Tom Lane 2007-07-31 17:10:13 Re: Export user visible function to make use of convert_to_scalar
Previous Message Tom Lane 2007-07-31 16:22:40 Re: [PATCHES] allow CSV quote in NULL