Beefy Boxes and Bandwidth Generously Provided by pair Networks
Problems? Is your data what you think it is?
 
PerlMonks  

Re^2: Fixed Position Column Records

by graff (Chancellor)
on Jul 22, 2007 at 02:30 UTC ( #628061=note: print w/replies, xml ) Need Help??


in reply to Re: Fixed Position Column Records
in thread Fixed Position Column Records

I would have posted a similar approach to induce probable column boundaries and then build a template string for unpack based on file data, but I had forgotten about the "string-OR" trick, so my code would end up much longer (and obviously was taking much longer to write).

Luckily for me, I rechecked the thread before getting to the tricky part in my approach (collapsing an array of character offsets into a pack template), and saw that there was a better way to do it (better in the sense of getting it done quicker with less code, as proven by the relative speed of your post).

++!

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://628061]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others rifling through the Monastery: (6)
As of 2020-08-07 12:45 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    Which rocket would you take to Mars?










    Results (45 votes). Check out past polls.

    Notices?