ca2006 Posted December 19, 2005 Share Posted December 19, 2005 Hi PHP Gurus, I am trying to get PHP working with INgres on IIS6.0. I downloaded PHP5.1.1 binary version and PECL library for Ingres support and confgured IIS6.0. I have the test PHP script <?php phpinfo() ?> working fine it displays all the PHP info. I have INgres-r3 installed and it is up and running. Now my questions, Question 1: Should I recompile PHP to get PHP-ingres extension (ingres_pconnect() ) working? If I have to recompile what are the options required to recompile. I downloaded php 5.1.1 src also. Question 2: I googled php-ingres support and found that PHP should be compiled with Ingres to get ingres working (NOT using ODBC). Please confirm this. Just to try, I compiled php src with these options cscript /nologo configure.js "--with-ingres=C:\opt\Ingres" "--without-iconv" "--disable-com-dotnet" "--without-gd" "--without-libxml" It compiled fine and I do have the compiled version. I have to sample scripts to test DB connection, test1.php <?php $connectionstring = odbc_connect("MDB", "admin", "admin"); $Query = "SELECT table_name FROM iitables"; $queryexe = odbc_do($connectionstring, $Query); odbc_result_all($queryexe, "BORDER=1"); odbc_close($connectionstring); ?> test2.php <?php $connection = ingres_pconnect("MDB", "admin", "admin"); ingres_query("select table_name from iitables"); while ($row = ingres_fetch_row()) { echo $row; } ?> test1.php is working fine with the PHP binary version I downloaded but does not work with the recompiled version. now the question is after I recompile should I copy any files from compiled version into the binary version or should I just use the new compiled version (I am currently setup to use the compiled version) If so what are the chnages required? test2.php does not work on either versions, Here is the error I am running into Fatal error: Call to undefined function ingres_pconnect() in C:\php\testpro\test2.php on line 6 I am struck on this for the past two days, I woud appreciate if anyone can anwser these questions. Thank you. Quote Link to comment https://forums.phpfreaks.com/topic/3072-php-n-ingres-configuration/ Share on other sites More sharing options...
ca2006 Posted December 19, 2005 Author Share Posted December 19, 2005 Ok, I read the readme doc it said to move .exe and .dlls to the working php dir. I did that now nothing is working. Fortunately I had the backup of the files I deleted, I restored them after that everything works fine. So, evedently something is worng with the build. Would someone reply with a solution please. Thank you. Quote Link to comment https://forums.phpfreaks.com/topic/3072-php-n-ingres-configuration/#findComment-10265 Share on other sites More sharing options...
ca2006 Posted December 19, 2005 Author Share Posted December 19, 2005 more info, I have used get_loaded_extensions() method to find the modules loaded, list is as below Array ( [0] => bcmath [1] => calendar [2] => com_dotnet [3] => ctype [4] => date [5] => ftp [6] => iconv [7] => odbc [8] => pcre [9] => session [10] => libxml [11] => standard [12] => tokenizer [13] => zlib [14] => SimpleXML [15] => dom [16] => SPL [17] => wddx [18] => xml [19] => ISAPI ) lib loading done - - 1 - evidently ingres module is NOT LOADED, but when I trace it from command line php -m ig gives me a different list - It lists INGRES MODULE C:\php>php -m bcmath calendar com_dotnet ctype date dom ftp iconv [b]ingres[/b] libxml odbc pcre session SimpleXML SPL standard tokenizer wddx xml zlib [Zend Modules] global shutdown C:\php> Would someone please explain what is going on; Your comments are really appreciated. Quote Link to comment https://forums.phpfreaks.com/topic/3072-php-n-ingres-configuration/#findComment-10267 Share on other sites More sharing options...
ca2006 Posted December 19, 2005 Author Share Posted December 19, 2005 Ok, I found the answer. for some reason php.ini file was not getting loaded when I started IIS server so I had to move the "php.ini" file to C:\Windows. That resolved it now my app loads ingres_pconnect() method. Quote Link to comment https://forums.phpfreaks.com/topic/3072-php-n-ingres-configuration/#findComment-10269 Share on other sites More sharing options...
ing Posted April 18, 2006 Share Posted April 18, 2006 [!--quoteo(post=328737:date=Dec 19 2005, 12:30 PM:name=ca2006)--][div class=\'quotetop\']QUOTE(ca2006 @ Dec 19 2005, 12:30 PM) 328737[/snapback][/div][div class=\'quotemain\'][!--quotec--] Hi PHP Gurus, I am trying to get PHP working with INgres on IIS6.0. I downloaded PHP5.1.1 binary version and PECL library for Ingres support and confgured IIS6.0. I have the test PHP script <?php phpinfo() ?> working fine it displays all the PHP info. I have INgres-r3 installed and it is up and running. Now my questions, Question 1: Should I recompile PHP to get PHP-ingres extension (ingres_pconnect() ) working? If I have to recompile what are the options required to recompile. I downloaded php 5.1.1 src also. Question 2: I googled php-ingres support and found that PHP should be compiled with Ingres to get ingres working (NOT using ODBC). Please confirm this. Just to try, I compiled php src with these options cscript /nologo configure.js "--with-ingres=C:\opt\Ingres" "--without-iconv" "--disable-com-dotnet" "--without-gd" "--without-libxml" It compiled fine and I do have the compiled version. I have to sample scripts to test DB connection, test1.php <?php $connectionstring = odbc_connect("MDB", "admin", "admin"); $Query = "SELECT table_name FROM iitables"; $queryexe = odbc_do($connectionstring, $Query); odbc_result_all($queryexe, "BORDER=1"); odbc_close($connectionstring); ?> test2.php <?php $connection = ingres_pconnect("MDB", "admin", "admin"); ingres_query("select table_name from iitables"); while ($row = ingres_fetch_row()) { echo $row; } ?> test1.php is working fine with the PHP binary version I downloaded but does not work with the recompiled version. now the question is after I recompile should I copy any files from compiled version into the binary version or should I just use the new compiled version (I am currently setup to use the compiled version) If so what are the chnages required? test2.php does not work on either versions, Here is the error I am running into Fatal error: Call to undefined function ingres_pconnect() in C:\php\testpro\test2.php on line 6 I am struck on this for the past two days, I woud appreciate if anyone can anwser these questions. Thank you. Am getting the same error too... can u please help me with the solution Quote Link to comment https://forums.phpfreaks.com/topic/3072-php-n-ingres-configuration/#findComment-28087 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.