Hi All
Please Help!
******************************************************
I am new to CGI and Perl.
I am trying to test a connect to the database
and execute a select against the TAB table.
The connect is hard coded for now. I am able
to pass the values in but I have not tried to use them
yet in the connect.
******************************************************
print "Content-type: text/html\n\n";
use strict;
use diagnostics;
use DBI;
use CGI qw(:standard);
print "<HTML>\n";
print " <BODY>\n";
print " <H1> Test Connection </H1>\n";
my $usr = param("usr");
my $pwd = param("pwd");
my $sid = param("sid");
print " <P> Username is <B>$usr</B> <BR>\n";
print " <P> Password is <B>$pwd</B> <BR>\n";
print " <P> Connect is <B>$sid</B> <BR>\n";
my $dbh = DBI->connect("dbi:Oracle:aux","ceb","ceb");
***************************************************************
The program is blowing up at the (my $cursor) statement.
***************************************************************
my $cursor = $dbh->prepare("select * from tab") || die "PREPARE
error $DBI::errstr\n";
# $cursor->execute();
# while (@row = $cursor->fetchrow())
# {
# print "$row[0]\n";
# }
# $db_handle->disconnect();
print " </BODY>\n";
print "</HTML>\n";
******************************************************
I'm getting this page source in NETSCAPE when it runs.
********************************************************
<HTML>
<BODY>
<H1> Test Connection </H1>
<P> Username is <B>ceb</B> <BR>
<P> Password is <B>ceb</B> <BR>
<P> Connect is <B>aux</B> <BR>
<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN">
<HTML><HEAD>
<TITLE>200 OK</TITLE>
</HEAD><BODY>
<H1>OK</H1>
The server encountered an internal error or
misconfiguration and was unable to complete
your request.<P>
Please contact the server administrator,
[EMAIL PROTECTED] and inform them of the time the error occurred,
and anything you might have done that may have
caused the error.<P>
More information about this error may be available
in the server error log.<P>
<HR>
<ADDRESS>Oracle HTTP Server Powered by Apache/1.3.19 Server at crtlit04 Port
80</ADDRESS>
</BODY></HTML>
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]