D'Arcy J.M. Cain wrote:
> On Wed, 28 Jan 2009 14:08:54 -0500
> Andrew Dunstan <andrew@dunslane.net> wrote:
>
>> D'Arcy J.M. Cain wrote:
>>
>>> I suppose we could define another line with options that we could
>>> define for meta information such as the border setting and the table
>>> name and whatever we define later. E.g:
>>>
>>> "table:person","border:3","funky:option with \":\""
>>>
>> Why do you want to add this extra information? psql doesn't output it
>> now, and IIRC your original proposal didn't do it either.
>>
>
> It mentioned including meta information. I'm not sure that I really
> care if I get it but we may want it in general, if not now then later,
> and it would be something that would be extremely hard to retrofit. If
> we start out with just the table and perhaps the border setting we can
> always add more later if we find we need it. If we don't start with
> something then adding an extra line later will cause all sorts of
> heartache.
>
>
For CSV it's likely to cause a headache right at the start. CSV with a
single header line is a well known and mostly understood format. I don't
know of any CSV processor (including ours) that handles more than one
header line.
This is actually an example of why XML is not such a bad choice. It is
rich enough that a processor is unlikely to be confused by metadata, and
capable of being turned into almost any other format you might want with
little difficulty.
cheers
andrew