in reply to Drop dead simple MySQL interface?
# fetching keys and values @keys = keys %h; @fields = keys %{$h{$keys[0]}}; print $h{'id1'}->{'field1'}; while (($key,$value) = each %h) { print "Key = $key:\n"; foreach (sort keys %$value) { print "\t$_ => $value->{$_}\n"; } } # changing data $h{'id1'}->{'field1'} = 'new value'; $h{'id1'} = { field1 => 'newer value', field2 => 'even newer value', field3 => "so new it's squeaky clean" };
All great truths begin as blasphemies.
― George Bernard Shaw, writer, Nobel laureate (1856-1950)
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: Drop dead simple MySQL interface?
by jabowery (Beadle) on Apr 05, 2012 at 14:23 UTC | |
by NetWallah (Canon) on Apr 05, 2012 at 15:29 UTC |