?
Solved

Displaying content from MySQL

Posted on 2003-03-30
2
Medium Priority
?
208 Views
Last Modified: 2010-03-05
I'm new to the DBI module, I was wondering how to pull the content from the database and have the web browser read it.  Are there any good area's on the web to learn how to do this?  I've seen plenty of articles, guides, & tutorials on how to post to the database but not read from the database.

Any help and/or guidance is/will be appreciated.
0
Comment
Question by:KenHeckert
2 Comments
 
LVL 51

Accepted Solution

by:
ahoffmann earned 150 total points
ID: 8234567

as you already knwo how to open a MySQL database, I leave this part out:

$sth=$dbh-prepare("SELECT*FROM table");
$sth->execute();
while (my $r=sth->fetchrow_arrayref()){
   my @arr=@{$r};
   print join( '<BR>', @arr );
}
# to be improved in many ways, for details see
#    man DBI
0
 
LVL 8

Expert Comment

by:Zlatin Zlatev
ID: 8366283
@KenHeckert, Do you need more help?
0

Featured Post

VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Email validation in proper way is  very important validation required in any web pages. This code is self explainable except that Regular Expression which I used for pattern matching. I originally published as a thread on my website : http://www…
A year or so back I was asked to have a play with MongoDB; within half an hour I had downloaded (http://www.mongodb.org/downloads),  installed and started the daemon, and had a console window open. After an hour or two of playing at the command …
Explain concepts important to validation of email addresses with regular expressions. Applies to most languages/tools that uses regular expressions. Consider email address RFCs: Look at HTML5 form input element (with type=email) regex pattern: T…
Six Sigma Control Plans
Suggested Courses

621 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question