Syntactic Confectionery Delight | |
PerlMonks |
Re^3: perl mysql - INSERT INTO, 157 columnsby graff (Chancellor) |
on May 02, 2014 at 16:52 UTC ( [id://1084812]=note: print w/replies, xml ) | Need Help?? |
Given that the OP specifically mentioned mysql, I would not have posted the approach using "describe" if it didn't work in mysql.
As for your alternative (for cases where "describe" doesn't work), I would hope that any type of database covered by DBD would at least support "select * from foo limit 1", and this would be a prudent usage for the task at hand, whether or not you actually need to execute the query in order to get field names. (BTW, thanks for the reminder about $")
In Section
Seekers of Perl Wisdom
|
|