Skip to content

Instantly share code, notes, and snippets.

@zoffixznet
Created October 9, 2016 05:17
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save zoffixznet/fb533e093a0084e3407e61643d509aa7 to your computer and use it in GitHub Desktop.
Save zoffixznet/fb533e093a0084e3407e61643d509aa7 to your computer and use it in GitHub Desktop.
use CSV::Parser;
my $fh = open './test.csv', :r;
my $parser = CSV::Parser.new( file_handle => $fh, contains_header_row => True );
my %icu_transfers;
until $fh.eof {
my %data = %($parser.get_line());
%icu_transfers{%data<NAME>} = %data if (%data<TRANSFER_TO> eq 'ICU')
}
say %icu_transfers;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment