Re: Oracle-PHP

From: Date: Fri, 22 Jun 2001 16:40:02 +0000
Subject: Re: Oracle-PHP
References: 1  Groups: php.db 
Request: Send a blank email to php-db+get-9746@lists.php.net to get a copy of this message
ORA-01034 meens that Oracle was not started up. From Oracle help, possible causes are : - the SGA requires more space than was allocated for it - the operating system variable pointing to the instance is improperly defined. the second one is probably yours. Are you sure you ORACLE_SID is called "sid" ?? isn'it "orcl" for example? An other thing, there is a third argument for OCILogon. In my case, I have to use it to connect to Oracle. the "Maximum execution time of 30 seconds exceeded" remembers me a problem with a SELECT very long, which needs more than 30 seconds to retrieve the rows. I had to use the php function set_time_limit() to increase the value. I hope it will help you. Best regards, Philippe "Vandana" <vandana@gdit.iiit.net> a écrit dans le message news: Pine.LNX.4.21.0106220102410.21531-100000@gdit.iiit.net... > > > I've just installed php4.0.4 , apache-1.3.14 and oracle8.1.6 > on my RedHat 7.0 machine.I am trying to write a php script to connect > to my oracle database.But I am facing problems.When I used the oci8 > functions as follows: > > <?php > putenv("ORACLE_SID=sid"); > putenv("ORACLE_HOME=/ora1/app/oracle/product/8.1.6"); > > line 11 if($conn=OCILogon("scott","tiger")) > { > echo("Successful:Connected\n"); > } > else { > echo("Connection failed\n"); > } > ?> > > the error message was: > > Warning:OCISessionBegin: ORA-01034: ORACLE not available in > /www/servers/index.php on line 11 > Connection failed > > ------------------------------------- > > And when I wrote the script with ordinary oracle function, > > replacing the OCILogon with a call to Ora_Logon, the error was as > following: > > Fatal error: Maximum execution time of 30 seconds exceeded in > /www/servers/index.php on line 11 > > ------------------------------------------- > > > Could somebody please help me with this problem? And > also, is there any good tutorial for PHP/Oracle ? > > > > > -- > PHP Database Mailing List (http://www.php.net/) > To unsubscribe, e-mail: php-db-unsubscribe@lists.php.net > For additional commands, e-mail: php-db-help@lists.php.net > To contact the list administrators, e-mail: php-list-admin@lists.php.net >

« previous php.db (#9746) next »