PEPPLER.ORG
Michael Peppler
Sybase Consulting
Menu
Home
Sybase on Linux
Install Guide for Sybase on Linux
General Sybase Resources
General Perl Resources
Freeware
Sybperl
Sybase::Simple
DBD::Sybase
BCP Tool
Bug Tracker
Mailing List Archive
Downloads Directory
FAQs
Sybase on Linux FAQ
Sybperl FAQ
Personal
Michael Peppler's resume

sybperl-l Archive

Up    Prev    Next    

From: jrisley at nex-web4 dot corp dot fedex dot com (Jason Risley)
Subject: problems with ct_execute
Date: Nov 26 1998 1:55AM

I am having troubles with ct_execute in a cgi script within Apache 1.3.3 on
NT. At the Command prompt, everything works just fine. But when I execute
this via Apache as a cgi script, I get the the following returned to the
browser:



I do not get any messages in Apache's error.log. Has anyone encountered this
problem and/or know how to solve the situation?

Thanks
Jason

The following is my perl script....

#!C:/sybperl/bin/perl.exe

	use CGI::Switch;
	use Sybase::CTlib;

	$uid = 'sa';
	$pwd = 'sa';
	$srv = 'sa';
	$charset = 'cp850';

	$! = 1;
	print "Content-type: text/html\n\n";
	print "\n";

	$db=Sybase::CTlib->ct_connect($uid, $pwd, $srv, $charset);
	$db->ct_execute("select uid, name from sysusers");
	while ( $db->ct_results($result) == CS_SUCCEED) {
	    next unless $db->ct_fetchable($result);
	    while ( ($uid, $name) = $db->ct_fetch ) {
      	  print "$uid - $name\n";
	    }
	}

	print "\n";