in reply to Record based XML stream processing?
use constant END_TAG = qr#</ArgusDataStream>#; my $xml = ""; while (<STDIN>) { my $line = $_; $xml .= $line; if ($line =~ END_TAG) { # Process the XML here... # Start again $xml = ""; } } [download]