Anonymous Monk has asked for the wisdom of the Perl Monks concerning the following question:
I'm using the following snippet without any luck$VAR1 = { 'response_1.3.6.1.2.1.2.2.1.12.27' => { 'Error_Status' => 'No error', 'Packets' => 1, 'OID_NAME' => [ [ '1.3.6.1.2.1.2.2.1.11.27', 'ifInUcastPkts.27' ], [ '1.3.6.1.2.1.2.2.1.15.27', 'ifInUnknownProtos.27' ], [ '1.3.6.1.2.1.2.2.1.14.27', 'ifInErrors.27' ], [ '1.3.6.1.2.1.2.2.1.13.27', 'ifInDiscards.27' ], [ '1.3.6.1.2.1.2.2.1.15.27', 'ifInUnknownProtos.27' ], [ '1.3.6.1.2.1.2.2.1.14.27', 'ifInErrors.27' ], [ '1.3.6.1.2.1.2.2.1.14.27', 'ifInErrors.27' ], ] }, 'request_1.3.6.1.2.1.2.2.1.12.27' => {
if ({$key_hash{$current_key}{OID_NAME}}->[0]->[1]) { print "Duplicate Found\n"; } else { push @{$key_hash{$current_key}{OID_NAME}}, [$oid, $name]; }
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Determining duplicate array elements
by pg (Canon) on Mar 24, 2003 at 16:38 UTC | |
|
Re: Determining duplicate array elements
by dragonchild (Archbishop) on Mar 24, 2003 at 15:56 UTC |