in reply to Paste comments in a document

Here is the finished(i use that term lightly as it is never really finished) script. I dont know if people usually post them when they are finished but in case someone else searches on this thread. Thanks again everyone.

#!/usr/bin/perl use strict; #use warnings; use DBI; my $all = (); my $EDO = (); my $comment = (); my $now = localtime(); my $result = (); my $dbargs = {AutoCommit => 0, PrintError => 1}; open (DATA, "@ARGV"); my $dbh = DBI->connect("dbi:SQLite:dbname=scan.db","","",$dbargs); while (<DATA>) { ($EDO) = /=EDO=([^=]+) Result=/ if /^=/; $all = $dbh->prepare("select comment FROM rr where EDO=\'$EDO\'"); $all->execute(); my $result = $all->fetchrow_hashref(); print; print "\nMitigation: $result->{comment}\n\n" if ( /^UNIX Checklis +t/ ); } close (DATA); $dbh->commit(); $dbh->disconnect(); __DATA__
Sean