#21491 [Opn->Bgs]: Hang during ociexecute
| From: | derick@php.net | Date: | Wed, 08 Jan 2003 10:17:53 +0000 |
| Subject: | #21491 [Opn->Bgs]: Hang during ociexecute | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-29429@lists.php.net to get a copy of this message | ||
ID: 21491
Updated by: derick@php.net
Reported By: stephan.rey@zurich.ch
-Status: Open
+Status: Bogus
Bug Type: OCI8 related
Operating System: Suse Linux 8.0
PHP Version: 4.2.3
New Comment:
Trust our document the next time please :-)
Derick
Previous Comments:
------------------------------------------------------------------------
[2003-01-08 03:38:22] stephan.rey@zurich.ch
Thanks champs!
The problem was the putenv()-statements. I've entered the definitions
for these variables right in front of the apache-start-script and know
it works great!
------------------------------------------------------------------------
[2003-01-07 14:49:54] michael.mauch@gmx.de
Does it help if you 'do it by the book',
<http://www.php.net/manual/en/ref.oci8.php>,
i.e. don't use putenv() or
Apache's SetEnv, but set the environment variables before you start
Apache? And did you check whether your Apache is linked to pthread (see
the page mentioned above)?
------------------------------------------------------------------------
[2003-01-07 09:32:33] kalowsky@php.net
Works fine on Solaris in DSO and CGI. You might want to test the
connection to see if it happened and call OCIError as well.
------------------------------------------------------------------------
[2003-01-07 08:19:04] stephan.rey@zurich.ch
I'm trying to get some (existing) records oput of an Oracle8-Database.
As long as I do a query, which can't have any results, everything works
fine. But if I write a SELECT-statement, which should give at least one
result, the whole thing hangs or I get the message 'The page cannot be
displayed'.
example (which causes me troubles):
<?php
putenv('ORACLE_HOME=/opt/oracle/OraHome1');
putenv('TNS_ADMIN=/opt/oracle/OraHome1/network/admin');
putenv('TWO_TASK=/opt/oracle/OraHome1/network/admin/tnsnames.ora');
$user="";
$pwd="";
$conn = ocilogon($user,$pwd,"TNEUN2");
$sql="select * from t_person WHERE name like 'Muster' ORDER BY name,
firstname, notes, racf";
$stmt=ociparse($conn,$sql);
ociexecute($stmt);
echo $sql;
?>
The 'echo-statement' is only used to verify that the script has
finished! The statement "select max(id_pers) from t_person" for example
works fine.
Thanks in advance!
Greetings
Stephan
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/?id=21491&edit=1