On Aug 16, Fontenot, Paul said: >while (my(@row) = $sth->fetchrow_array) >{ > my $ip = $row[0]; > next if $ip == "010.041.\*";
That line will always be false. You probably mean next if $ip eq '010.041.*'; But if you really wanted to do a wildcard-like equality, you'd need a regex; something like: next if $ip =~ /010\.041\..*/; > my $name = $row[1]; > > my $mso = $row[2](m/MS\d\d\-\d{3}/); my ($mso) = $row[2] =~ /(MS\d\d-\d\d\d)/i; > my @date = split/ /, $row[3]; You *probably* would be safer with my @data = split ' ', $row[3]; There is a slight difference; 'perldoc -f split' explains it. > my $severity = $row[4]; > > printf "%-15s %-35s %-10s %-10s %-10s\n", $ip, $name, $mso, >$date[0], $severity; >} -- Jeff "japhy" Pinyan % How can we ever be the sold short or RPI Acacia Brother #734 % the cheated, we who for every service http://japhy.perlmonk.org/ % have long ago been overpaid? http://www.perlmonks.org/ % -- Meister Eckhart -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] <http://learn.perl.org/> <http://learn.perl.org/first-response>