Hi -
Maybeeee...
if ($usr == $usr1) {print "$usr $pass $email\n";}
'==' is a NUMERIC compare, 'eq' is the corresponding alphanumeric compare.
So:
if ($usr eq $usr1) {print "$usr $pass $email\n";}
or (to ignore case):
if (lc $usr eq lc $usr1) {print "$usr $pass $email\n";}
-----Original Message-----
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]On Behalf Of Francesco
Guglielmo
Sent: Friday, May 17, 2002 6:17 AM
To: [EMAIL PROTECTED]
Subject: Who debug me?
That's the problem:
#!/usr/bin/perl
my $file = '/home/users/francesco/LISTAORDINATA.txt';
my $outfile = '/home/users/francesco/Perl/file/usrpasswdemail.txt';
my $file2 = '/home/users/francesco/Perl/file/peralberto.txt';
open (OUT, ">$outfile");
open (INPUTEMAIL, "$file2");
# open (INPUTPASS, "$file");
while (<INPUTEMAIL>) {
chomp;
($usr1,$email) = split (/\s/);
open (INPUTPASS, "$file");
while (<INPUTPASS>) {
chomp;
($usr,$pass) = split (/\s/);
if ($usr == $usr1) {print "$usr $pass $email\n";}
}
}
Where is my error?
I suppose in the "if".....
I want to print $usr $pass $email
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]