Beefy Boxes and Bandwidth Generously Provided by pair Networks
Your skill will accomplish
what the force of many cannot
 
PerlMonks  

Re^2: Retrieving column names from SQL with DBI

by Tux (Abbot)
on Sep 25, 2020 at 09:16 UTC ( #11122194=note: print w/replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    my $sth = $dbh->prepare ("select * from foo");
    $sth->execute;
    ...
        # Do something with the record. Fields are stored in %r
        printf "%-16s: %s\n", $_, $r{$_} // "--undef--" for @fields;
        }
    

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others perusing the Monastery: (1)
As of 2021-02-26 04:43 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found

    Notices?