pyparsing question
Neil Cerutti
mr.cerutti at gmail.com
Tue Jan 1 18:59:15 EST 2008
On Jan 1, 2008 6:54 PM, Neil Cerutti <mr.cerutti at gmail.com> wrote:
> There's no standard Python tool for reading and writing fixed-length field
> "flatfile" data files, but it's pretty simple to use named slices to get at
> the data.
>
> identifier = slice(0, 8)
> timestamp = slice(8, 18)
> t = slice(18, 21)
> c = slice(21, 24)
> resource_name = slice(24, 35)
> description = slice(35)
Oops! I made an errant stab at the slice constructor. That last should be
'slice(35, None)'.
--
Neil Cerutti
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/python-list/attachments/20080101/4bd9b4b1/attachment-0001.html>
More information about the Python-list
mailing list