my $hashref = sub { return $dbh->selectrow_array("SELECT * FROM users"); }; print $hashref->(),"\n"; print $hashref->(),"\n";