#3 Problems with tab and space delimiters

closed-fixed
Cliff Wells
None
5
2002-10-24
2002-10-08
Nigel Hathaway
No

If you use tab (or space) as a delimitier then any trailing
blank fields are lost, and the columns after shifted over
accordingly.

This is caused by 'whitespace' being stripped from the
beginning and end of a line before it is parsed (DSV.py
line 455).

I would question the stripping of whitespace from a line
anyway. If a DSV file has whitespace at the beginning or
end, why was it put there? Excel doesn't 'accidently' do
this. I would tend to say that such whitespace would be
put there deliberatley as part of the field. If not, you
could argue that whitspace surrounding each field
should be ignored. Besides, whitespace between a
delimiter and a text qualifier breaks DSV's algorithm (the
big regular expression doesn't take this possibility into
account).

Discussion

  • Cliff Wells
    Cliff Wells
    2002-10-24

    • assigned_to: nobody --> cliffwells18
    • status: open --> closed-fixed