[Zope] Comma delimited file and the re python object
Stuart 'Zen' Bishop
zen@cs.rmit.edu.au
Fri, 5 Nov 1999 11:26:08 +1100 (EST)
On Thu, 4 Nov 1999, Max M wrote:
> I am trying to import a comma delimited ascii file via Python.
>
> naturally the pattern: , will not work as there might be a comma inside the
> text.
>
> the pattern "," wont work either as there as the numbers are not enclosed in
> quotes.
>
> There must be a simple pattern doing it right but I cannot seem to figure it
> out myself.
Have a look at the shlex library distributed with python 1.5.2.
___
// Zen (alias Stuart Bishop) Work: zen@cs.rmit.edu.au
// E N Senior Systems Alchemist Play: zen@shangri-la.dropbear.id.au
//__ Computer Science, RMIT WWW: http://www.cs.rmit.edu.au/~zen