|Welcome to the Monastery|
Perl - MySQL query questionby peppiv (Curate)
|on Mar 08, 2002 at 15:40 UTC||Need Help??|
peppiv has asked for the wisdom of the Perl Monks concerning the following question:
I have a MYSQL database that I query using Perl and all its excellent DBI capabilities. The database is a compilation of surveys we take online. I'm building a reporting page that summarizes the surveys and I'm sure there's a much better way to do it.
Here's a sample of what I'm doing.
Obviously, I want (for formatting purposes) to write each response to it's own table row (three columns wide).
I know I should be using the 'do' command. I'm sure there's some way to this with lists or arrays that would be much quicker and cleaner. Can someone help me optimize this cumbersome code?
Also, I have some answers in the database that are not in the list of selections. Is there an easy way to query the MySQL for all values in a column and print/list them to the page?
I'm on FreeBSD-Perl 5-MySQL 3.23
I'm also on milk, but that's another story