NAME and NUM_OF_FIELDS are magic attributes of a statement handle that are supported by many DBDs.my $names = $sth->{'NAME'}; my $numFields = $sth->{'NUM_OF_FIELDS'}; for (my $i = 0; $i < $numFields; $i++) { printf("%s%s", $$names[$i], $i ? "," : ""); }
In reply to Re: Getting Column Names from DBI?
by dws
in thread Getting Column Names from DBI?
by vivekvp
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |