Solved

CGI

Posted on 2004-08-04
4
224 Views
Last Modified: 2010-05-18
i want to be able to view certain data from the database and though of using CGI to display it.
can Perl CGI be used to extract data from database? (50 pts)
If so, can anyone show me? the steps perhaps (will add on pts)

thanks
0
Comment
Question by:TPoly
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
4 Comments
 
LVL 20

Expert Comment

by:jmcg
ID: 11722910
Yes, it can. There are several experts here who will be glad to help you but for an example to be more useful to you, it would help to know some specifics:

what database product(s) are you using?

do you have a sample SQL statement that produces the data you want displayed?

In addition to the CGI module, you'll most likely end up with the DBI module and one of the DBD driver modules.

=============

Some databases have native web interfaces that work out-of-the-box for simple stuff and can be customized to do less simple stuff. Sometimes it's better to use Perl, sometimes it's better to embrace the product.
0
 

Author Comment

by:TPoly
ID: 11724029
ok thanks..

I'm using Mysql.

Sample SQL statement: select job from test where job = "abc";
Is this what you mean by sample SQL statement?

0
 
LVL 84

Expert Comment

by:ozo
ID: 11724056
0
 
LVL 20

Accepted Solution

by:
jmcg earned 50 total points
ID: 11725462
Here a couple of older questions that contain examples of retrieving data from a MySQL database and formatting the results as an HTML table. I'm not sure selecting from one column is going to get you an interesting table, but if you take a look at these examples, I'm sure you can adapt them to do what you want.

http:Q_20995819.html

http:Q_20873609.html

The experts who contributed those answers are still active here and you should be able to get answers to any further questions you have.
0

Featured Post

Enroll in July's Course of the Month

July's Course of the Month is now available! Enroll to learn HTML5 and prepare for certification. It's free for Premium Members, Team Accounts, and Qualified Experts.

Question has a verified solution.

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

I've just discovered very important differences between Windows an Unix formats in Perl,at least 5.xx.. MOST IMPORTANT: Use Unix file format while saving Your script. otherwise it will have ^M s or smth likely weird in the EOL, Then DO NOT use m…
There are many situations when we need to display the data in sorted order. For example: Student details by name or by rank or by total marks etc. If you are working on data driven based projects then you will use sorting techniques very frequently.…
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

632 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