Need help converting text to csv format

r0g aioe.org at technicalbloke.com
Sun Nov 23 18:13:42 EST 2008


John Machin wrote:
> On Nov 22, 11:04 am, r0g <aioe.... at technicalbloke.com> wrote:
>>>>>>>> On Nov 21, 10:18 am, Chuck Connors <don... at gmail.com> wrote:
>>>>>>>>> Any help, pseudo code, or whatever push in the right direction would
>>>>>>>>> be most appreciated.  I am a novice Python programmer but I do have a
>>>>>>>>> good bit of PHP programming experience.
>> <snip>
>>
>> John Machin wrote:
>>> If I had to write such a script in Python, I'd be using the re and csv
>>> modules in similar fashion to responses already posted. If I had to
>>> write it in PHP, it'd be my first PHP script, so let's go Googling:
>>> google("php regex") first hit:
>>> http://www.regular-expressions.info/php.html
>>> [yuk, 3 different toolkits; 3rd is PCRE, let's try that]
>>> google("php csv") 3rd hit points to:
>>> http://www.php.net/manual/en/function.fputcsv.php
>>> Doesn't seem too difficult to me.
>> I'm sure it doesn't, it doesn't to me either, but only because we
>> already know what he needs! Do you think if the OP knew all about
>> regular expressions and understood that python has a handy csv module
>> that he'd be asking this question here?
> 
> (1) csv: The OP already knows what "csv" means -- see the subject
<snip content="blah blah blah">

As I and others have said a more appropriate response is no response.

Not everyone is aspiring to become a python guru. Some people have
things to do, timescales to work to and aren't professional programmers.

If I can spare someone a whole afternoon of slogging through manuals by
spending two minutes of my time answering them then I see no reason not
to, even if it spares them the 'rite of passage' learning you seem to
think they must endure.

What you experts deem so easy it's rude to ask about is a subjective
thing. I personally see a world of difference between the oldschool "Me
wan make game! Show me how make 3D game C++" posts you might see on
usenet and this guys polite detailed request for pointers.

Anyway shouting someone down for causing what you see as noise in your
forums is just increasing the noise for yourself and everyone else. Not
only that it clogs up the many web archives of this forum making people
who do google for answers to these 'easy' topics that little bit more
likely to run into your RTFM rant than the answer i.e. a bit less likely
to find the thing they're looking for and therefore more likely to come
to places like this to ask their 'trivial' questions and annoy you.

Roger.



More information about the Python-list mailing list