There's more than one way to do things | |
PerlMonks |
comment on |
( [id://3333]=superdoc: print w/replies, xml ) | Need Help?? |
Hi I have a text file in the format below:
Basically it is a tagged file and I need to load it into a hash. As you can see it has potentially has more than one line per tag. I want to create a hash that maps each tag (tags are unique) to an array of the lines associated with that tag, i.e.
Tag names are always two letter but may be arbitrary and therefore cannot be hardcoded, however, the file is always terminated by a tag named ER. Can anyone provide me with the code to translate this text into a hash to my requirements, I just can't seem to handle the multiline case. Thanks in advance ____________Arun In reply to Parsing a Tagged File Format by arunhorne
|
|