I'm getting errors in a perl script that requires an xml input file. I keep getting the following error: main::running uncatalog for dcs entries /uncatalog.pl failed: Please investigate ] STDERR : [Not a HASH reference at /uncatalog.pl line 56. The code it is referencing is listed below, lines 51 through 67
51 # Iterate over the configuration types listed in @type_ord +er 52 foreach my $type (@type_order) { 53 print "$log_pre running $action for $type entries\ +n"; 54 # Iterate over all items of that type 55 my $type_hash = $hashref->{$type}; + #shortcut to smaller hash 56 foreach my $item (keys %{$type_hash}) { 57 print "$log_pre running $action for $type +$item\n"; 58 my $item_hash = $type_hash->{$item}; + #shortcut to smaller hash 59 #Add values for type and action into the h +ash 60 $item_hash->{'name'} = $item; 61 $item_hash->{'type'} = $type; 62 $item_hash->{'action'} = $action; 63 #print Dumper($item_hash); 64 #execute action for the individual configu +ration 65 unless (db2_mgmt_cat(\%{$item_hash})) { 66 #unless (db2_mgmt_cat(\%{$type_hash})) { 67 # Return false if the action could + not be completed successfully.
In reply to Not a HASH reference error by briandanderson1977
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |