I am curious, when I look at your input, I see 11 comma separated fields. When I look at your hash record field names, I see 12. Where did 'ap_name' go to or rather where could it come from? There seems to be a field missing. Perhaps I am blind and/or am miscounting. Either thing could be! I am also curious as to why you wouldn't use the same $var name as the hash key, ie, instead of my $new_name = $records->{'ap_name'}; Why not my $ap_name = $records->{'ap_name'} ?