if(undef($text)) { ... #### foreach my $row (@{$data_all}) { say $row; my %currec = %{$row}; foreach my $columns (keys %currec) { my $text = $currec{$columns}; say $text; if(! defined ($text)) { say "$columns is NOT DEFINED"; } elsif (length($text) < 1) { say "$columns DEFINED, but empty"; } } exit; }