http://qs321.pair.com?node_id=660517


in reply to Re: hash from CSV-like structure
in thread hash from CSV-like structure

A couple of minor quibles : DBD::CSV defaults to having binary on when it calls Text::CSV_XS, and while it's good advice to turn binary on by default, it really isn't true that "you always want to use the binary option" since there are several CSV formats which you *want* to fail if they encounter embedded newlines. I was tempted to point the OP to one of those modules too, but this data has no embedding and would need to have its terminal field separator chomped so doing it by hand seems just as good for this one particular case.