#! perl use strict; use warnings; my $file='test.txt'; open(test,"<", $file) or die "konnte $file nicht oeffnen ($!)"; while(my $line=) { chomp($line); my @pairs=split(/,/,$line); for my $pair (@pairs) { my ($key,$value)=split(/=/,$pair) print "$key $value\n"; } } close(test);