Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl Monk, Perl Meditation
 
PerlMonks  

Re: mysql pull back highest column

by jZed (Prior)
on Aug 20, 2007 at 21:46 UTC ( [id://633950]=note: print w/replies, xml ) Need Help??


in reply to mysql pull back highest column

I am not really sure what you are asking but I am going to guess (pretend?) that your question is: Is there a way in DBI to fetch a single value from a database without explicitly doing prepare, bind, execute, fetch, finish as single steps? And the answer is, yes!
my $dbh = DBI->connect(...); my($max_foo) = $dbh->selectrow_array(q{ SELECT MAX(foo) FROM bar });

Log In?
Username:
Password:

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

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

    No recent polls found