Beefy Boxes and Bandwidth Generously Provided by pair Networks
We don't bite newbies here... much

Re^3: Columnwise parsing of a file

by topher (Scribe)
on Feb 26, 2013 at 16:15 UTC ( #1020719=note: print w/replies, xml ) Need Help??

in reply to Re^2: Columnwise parsing of a file
in thread Columnwise parsing of a file

How in this case I would handle the spaces each cell (eg: col 0 row 1 etc) content is having.

If you are using spaces as field delimiters, and you have (non-escaped) spaces in your data, you don't handle it. You're asking the wrong question and trying to solve the wrong problem.

The problem isn't how to parse the data, it's how to get valid data. Data in a format that can't be cleanly parsed is what we usually call garbage data.

A well known maxim in the Database world (and elsewhere in IT), is "Garbage in, Garbage out". If you can't provide good data to process, or come up with a way to clean up your data before processing, you will never valid, reliable, trustworthy results out.

Additionally, once you find a way to either get clean data or properly clean up your data, the parsing will likely be much simpler to figure out.

Christopher Cashell

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1020719]
and all is quiet...

How do I use this? | Other CB clients
Other Users?
Others perusing the Monastery: (7)
As of 2018-02-21 08:21 GMT
Find Nodes?
    Voting Booth?
    When it is dark outside I am happiest to see ...

    Results (276 votes). Check out past polls.