my %HoA; print "Input Data parsed into 3 columns:"; while (my $line = ) { my ($col1,$restcol) = split /:\s*/, $line ,2; my @restColumns = split '', $restcol; $HoA{$col1} = [@restColumns]; } print "Dumping Output \n"; for my $dataKey (keys %HoA) { print "$dataKey: ", join("\t\t", @{$HoA{$dataKey}}), \n"; } __DATA__ ULTRIX : CW18.72.0.3 IP-HOST1.log DEC_DECSTATION : CW180.72.0.3 IP_HOST_AL.log DEC_DECSTATION_ADDR : CW180.72.0.3 IP_HOST_al2.log FOR_VISITORS23_HOST : HL617.253.1101.2 IP_HOST_hostinfo.log FOR_VISITORS24_HOST : HL617.253.1101.2 IP_HOST_hostinfo2.log FOR_VISITORS25_HOST : HL617.253.1101.2 IP_HOST_webform3.log FOR_VISITORS25_HOST : HL617.253.1101.2 IP_HOST_webform4.log FOR_VISITORS25_HOST : HL617.253.1201.2 IP_HOST_webform4.log #### FOR_VISITORS25_HOST HL617.253.1201.2 IP_HOST_webform4.log DEC_DECSTATION CW180.72.0.3 IP_HOST_AL.log FOR_VISITORS23_HOST HL617.253.1101.2 IP_HOST_hostinfo.log DEC_DECSTATION_ADDR CW180.72.0.3 IP_HOST_al2.log ULTRIX CW18.72.0.3 IP-HOST1.log FOR_VISITORS24_HOST HL617.253.1101.2 IP_HOST_hostinfo2.log #### FOR_VISITORS25_HOST HL617.253.1101.2 IP_HOST_webform3.log FOR_VISITORS25_HOST HL617.253.1101.2 IP_HOST_webform4.log #### FOR_VISITORS25_HOST HL617.253.1101.2 : IP_HOST_webform3.log FOR_VISITORS25_HOST HL617.253.1101.2 : IP_HOST_webform4.log #### FOR_VISITORS25_HOST HL617.253.1101.2 IP_HOST_webform3.log IP_HOST_webform4.log ...... ......