#!/usr/bin/perl -w use strict; my $data; # open file open FILE , "< /home/you/your.file"; # extract data and store it in a hash of tables while( ) { @_ = split; $_ = shift @_; $data->{$_} = [@_]; } # close file ;) close( FILE ); # display result foreach( keys %{$data}) { print $_ , "\t" , join "\t" , @{$data->{$_}} , "\n"; } #### use enlightment; # ( thx clintp :)