Beefy Boxes and Bandwidth Generously Provided by pair Networks
Welcome to the Monastery

Re: accessing field names in Access table?

by bart (Canon)
on Sep 18, 2003 at 09:07 UTC ( #292341=note: print w/replies, xml ) Need Help??

in reply to accessing field names in Access table?

You can access a list of the field names out of a prepared SELECT statement, by using $sth->{NAME}, which returns an array reference — you can turn it into an array/list using @{$sth->{NAME}}. If you want them all converted to uppercase or lowercase, use $sth->{NAME_uc} or $sth->{NAME_lc}.

Perhaps you want something else. Perhaps you want a complete description of all tables in a database. You don't say. There are ways, yes, but they're generally very driver (red: "DBD") specific. I'm not familiar enough with DBD::ODBC to know the specifics for this driver. I could check if you're really interested.

Log In?

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

How do I use this? | Other CB clients
Other Users?
Others romping around the Monastery: (5)
As of 2022-11-30 20:00 GMT
Find Nodes?
    Voting Booth?