Beefy Boxes and Bandwidth Generously Provided by pair Networks
Don't ask to ask, just ask
 
PerlMonks  

Re: DBI Style Inquiry

by kcott (Abbot)
on Jun 27, 2013 at 08:52 UTC ( #1040962=note: print w/ replies, xml ) Need Help??


in reply to DBI Style Inquiry

G'day edict,

Welcome to the monastery.

Take a look at the Perl style guide for some general guidelines on formatting your code.

With the specific code you posted, you're returning from the subroutine before the last two statements are run. You probably want something closer to this:

sub get_loc { ... my @loc = ... $sth->finish; $dbh->disconnect ... return @loc; }

-- Ken


Comment on Re: DBI Style Inquiry
Download Code
Re^2: DBI Style Inquiry
by edict (Novice) on Jun 27, 2013 at 09:12 UTC
    I appreciate the link, I'll check it out, thanks!

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others cooling their heels in the Monastery: (11)
As of 2014-07-23 21:21 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    My favorite superfluous repetitious redundant duplicative phrase is:









    Results (152 votes), past polls