in reply to searching two files

Hi,

Your comparison operator is wrong...

You should have use the following:

OPTION 1:
if ( $nameA == $nameB ) { print "$nameA, $machine, $password\n"; }
OPTION 2:
if ( $nameA =~ m#^$nameB$#) { print "$nameA, $machine, $password\n"; }

Regards,

Gopal.R