Beefy Boxes and Bandwidth Generously Provided by pair Networks
Clear questions and runnable code
get the best and fastest answer
 
PerlMonks  

Re: find differences between multiple hashes

by tachyon (Chancellor)
on Apr 10, 2004 at 06:42 UTC ( [id://344093]=note: print w/replies, xml ) Need Help??


in reply to find differences between multiple hashes

Data::Diff or Struct::Diff will tell you if the structures differ. To drill down and compare arbitrary perl structures to generate a perl structure of the diffs is a task similar (but more complex) than that done by Data::Dumper Data::Denter or YAML.

AFAIK there is no module that currently does this. I would suggest that writing a minimum case to deal with your data (like it sounds your have) is the best solution short of rethinking the app logic. BTW your desired result output is logically inconsistent (as noted by kvale) and should also contain 'name' => 'test1'.

cheers

tachyon

  • Comment on Re: find differences between multiple hashes

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://344093]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others contemplating the Monastery: (4)
As of 2024-04-18 04:06 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found