From: | Andrew Dunstan <andrew(at)dunslane(dot)net> |
---|---|
To: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
Cc: | pgman(at)candle(dot)pha(dot)pa(dot)us, chriskl(at)familyhealth(dot)com(dot)au, pgsql-hackers(at)postgresql(dot)org |
Subject: | Re: Different length lines in COPY CSV |
Date: | 2005-12-12 20:08:37 |
Message-ID: | 439DD8C5.6050502@dunslane.net |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
Tom Lane wrote:
>>Where would you want this file conversion
>>utility? bin? contrib? pgfoundry?
>>
>>
>
>I'd say pgfoundry for starters --- there's no reason to tie it down
>to server release cycles. Maybe when the thing is fairly mature and
>doesn't need frequent releases, we could think about whether it ought
>to be brought into the core distro.
>
>However, it likely won't ever be a candidate to become part of core
>unless it's written in C, and offhand I would judge C to not be the
>best choice of implementation language for such a thing. This is surely
>going to be mostly a string-pushing type of problem, so something like
>perl might be a better bet.
>
>
>
>
You are probably right. The biggest wrinkle will be dealing with various
encodings, I suspect. That at least is one thing that doing CSV within
the backend bought us fairly painlessly. Perl's Text::CSV_XS module for
example simply handles this by declaring that only [\x09\x20-\x7f] are
valid in its non-binary mode, and in either mode appears to be MBCS
unaware. We should try to do better than that.
cheers
andrew
From | Date | Subject | |
---|---|---|---|
Next Message | Frank Wiles | 2005-12-12 20:14:39 | Re: Something I don't understand with the use of schemas |
Previous Message | Jim C. Nasby | 2005-12-12 20:05:03 | Re: Something I don't understand with the use of schemas |