in reply to Numerical sorting issues with a hash of hashes

cmp does a string comparison. <=> does a numerical comparison. I could give a bit more help if I saw more of your code, since some if it is confusing me. For instance, this:
sort { keys %{$event_hash{$key}{$b}} cmp keys %{$event_hash{$key}{$a}} + } keys %event_hash;
will sort based on the number of keys in the subhashes, not their value. (or so I think, since output of keys will be cast scalar by the cmp operator, yes?)