From:             [EMAIL PROTECTED]
Operating system: Linux Server 2.2.14-6.1.1
PHP version:      4.0.6
PHP Bug Type:     OCI8 related
Bug description:  "break;" doesn't seem to work propery

I'm not sure this is a bug.

Maybe one cannot just "break" out of an "if" or "else" block.

I have a html page that accepts a username and password and then calls the
code below.


if ((!$username) || (!$password)) {


$connection = OCILogon($username, $password, $db);
if ($connection == false){
   $msg = OCIError($connection)."<BR>";
else do {
        // Looks like we need the "do..while()" so we can "break;" below!
        $stmt = "select * from \"Person\"";
        $cursor = OCIParse($connection, $stmt);
        if (false == $cursor){
                $msg = OCIError($cursor)."<BR>";

        $result = OCIExecute($cursor);
        if (false == $result) {
                $msg = OCIError($cursor)."<BR>";

        echo "<table border=1>";
        echo "
                        <td><b>Person Name</b></td>
                        <td><b>Person Information</b></td>

        while (OCIFetchInto ($cursor, $values)){
                $leID = $values[0];
                $pName = $values[1];
                $pInfo = $values[2];

                echo "

        echo "</table>";

} while (false);

<TITLE>Secret Area</TITLE>

                <? echo "$msg"; ?>

                <form method="POST" action="";);>
                <input type="submit" name="logon" value="Back">


The problem is that if I use a user which doesn't have the
"Person" table in its schema the second "break;" (OCIExecute()) causes the
following error:

Warning: OCIStmtExecute: ORA-00942: table or view does not exist in
/home/httpd/html/sec_html/logon.php on line 25

Fatal error: Cannot break/continue 1 levels in
/home/httpd/html/sec_html/logon.php on line 29

My configure line was:
./configure  --without-mysql --with-oci8 --with-apache=../apache_1.3.20
--enable-track-vars --with-openssl

Best regards,
Andrei Lenkei
Edit bug report at:

PHP Development Mailing List <>
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]

Reply via email to