I work for NYS Department of Health. We have a large Public Health Network which operates on SUN boxes with Sybase ASE SQL. Most of the applications are written in a combination of Perl, Java, HTML, Javascript.
My group is responcible for a major application was developed to collect Labs information. This application is written largely in PowerDynamo, HTML, JavaScript, and Perl using an abundant amount of stored procedures.
PowerDynamo is similar to Cold Fusion melding HTML and JavaScript to provide connectivity to Sybase SQL Servrers.
I am investigating the possibility of replacing the PowerDynamo with PHP. On the surface it appears that we would not be in for a major rewrite as we would if we were to employ JSP as an alternative. PowerDynamo is a dead product in the eyes of Sybase as well as most of the Sybase Developer community.
I first became interested in PHP when we attempted to move the existing application to Laptop computers for purpose of taking to presentations.
I found that the combination of the MS Personal Web Server and PowerDynamo was very unstable. I began looking for a better Web Server for the Laptop computers which lead me to Apache. To date I have never been able to get PowerDynamo to work with the Apache Web Server.
In learning about the Apache Web Server I began to seeing the PHP product being discussed as a SQL Server interface. So I began investigating PHP at that point.
So for I have PHP, MySQL, and Apache functioning properly in Win2000. Sybase is functioning properly as well in the ODBC interface to SQLAdvantage, Access, PowerBuilder, etc. When I attempt to connect the PHP code to the Sybase server it fails giving the following error message:
======================================
I put together a short piece of code based on a the Sybase sample that is posted on Thickbook.com site (http://www.thickbook.com/extra/php_sybase.phtml) just to check the ability to connect the Apache Web Server through PHP to a Sybase ASE SQL Server in a Windows 2000 OS environment.
I ran into problems the working the PHP4 build, Apache, and Sybase ASE.
I had downloaded PHP4 from several InterNet locations and none have worked properly when connecting to Sybase ASE through an Apache Web Server in a Win2000 OS.
===========================================
<?php
// create connection
$connection = sybase_connect("NEWDEV","sa","smile10")
or die("Couldn't make connection.");
// select database
$db = sybase_select_db("psdemodb", $connection)
or die("Couldn't select database.");
// free resources and close connection
sybase_free_result($sql_result);
sybase_close($connection);
?>
=======================================
Apache, PHP4, MySQL, and IE5 work well in Win2000.
Sybase ASE is working and can be connected to by SQL Advantage, Access and other tools using ODBC.
========================================
On my home computer I get the following error message from Apache/PHP.
The instruction at "0x00a555b1" referenced memory at "0xa5ed7940".
The memory could not be "written".
Click on OK to terminate the program
Apache/1.3.14 Server at 127.0.0.1 Port 80
This has happened several times with several builds of the Apache, PHP, and reloading fresh installs of the Win 2000 OS just to be sure.
PHP Version 4.0.5-dev
Windows NT 5.0 build 2195 / Jan 12 2001
Sybase 11.9.2 ASE for Windows NT
========================================
At work it sometimes writes the following error to the Apache error.log:
[Thu Jan 18 21:39:32 2001] [error] [client 127.0.0.1] Premature end of script
headers: c:/php4/php.exe
As soon as I comment out the sybase_connect() line the rest of the script executes properly although the other sybase calls generate error messages due to the fact that a connection does not exist. So the scripting is not the problem.
Bottom Line =========================================
Is there some place where I could receive assistance in PHP, APACHE, SYBASE to work together in a Win2000 OS environment.
I would be willing to purchase a version of PHP that support Sybase in the above configuration. sjm05@health.state.ny.us
I have details of the error message and supportive set-up information, but this format does not support the presentation of such materials.