in reply to Creating One Table From Several Hashes

I was writing up a bit more, but then noticed the number of posts that appeared. So just three quick notes:

  1. You have a CSV file, so rather than using substr with fixed-width columns, perhaps you should consider using Text::CSV. It will make you code more resilient and you'll spend less time thinking how to parse the file.
  2. Given you want to organize by an arbitrary number of dates by zip code, it seems like you should use a hash of hashes keyed on ZIP (as others have suggested) - see perllol for operational details.
  3. From the content of your files, it sounds like these are pulled from a database. Is there a reason you are using local files as an intermediary rather than DBI?
    • Comment on Re: Creating One Table From Several Hashes

Replies are listed 'Best First'.
Re^2: Creating One Table From Several Hashes
by bryced1234 (Initiate) on Feb 26, 2009 at 03:38 UTC
    Thanks for the info (DBI looks useful). I actually misspoke in my original post. The data that I am using is fixed-width, so substr is the way to go. Sorry for the confusion. I am a first time poster here. Next time I will be more precise with my language.