in reply to Simple SQL like thingy?

Hello ,


This is one of the ways to do it :
foreach $id (keys %hashes) { push @ids, $id if ( cond($hashes{$id}) ); } sub cond { my %line = %{shift}; return ( ( ($line{'key1'} eq "foo") and ($line{'key1'} eq "bar") ) or ($hashes{$id}{'key4'} < 10) ); }
Then @ids contains all the ids that correspond to your request.

HTH

Update: made the code cleaner

--
zejames