[Csv] CSV interface question
Skip Montanaro
skip at pobox.com
Thu Jan 30 02:47:20 CET 2003
Andrew> In the proposed PEP, we have separate instances for reading and
Andrew> writing. In the Object Craft csv module, a single instance is
Andrew> shared by the parse and join methods - the only virtue of this
Andrew> is config is shared (so the same options are used to write the
Andrew> file as were used to read the file).
...
Andrew> The idea being you'd then re-write the file with the same
Andrew> sniffed options.
In my work, I rarely read and write the same file. I either read a file,
then shoot it to a database or go the other way. In situations where the
input and output are both CSV files, at least one is stdout, and there is
almost always something different about the reading and writing parameters.
Andrew> Another idea occurs - looping over an iteratable is going to be
Andrew> common - we could probably supply a convenience function, say
Andrew> "writelines(iteratable)"?
Seems reasonable.
Skip
_______________________________________________
Csv mailing list
Csv at mail.mojam.com
http://manatee.mojam.com/mailman/listinfo/csv
More information about the Csv
mailing list