Bug #1972 Updated: while kills while loop
| From: | sander@php.net | Date: | Sun, 16 Jun 2002 12:35:51 +0000 |
| Subject: | Bug #1972 Updated: while kills while loop | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-10654@lists.php.net to get a copy of this message | ||
ID: 1972
Updated by: sander@php.net
Reported By: commy_@hotmail.com
-Status: Open
+Status: Bogus
Bug Type: Misbehaving function
Operating System: Windows NT
PHP Version: 3.0.11
New Comment:
Thank you for taking the time to report a problem with PHP.
Unfortunately, PHP 3 is no longer supported. Please download
the latest version of PHP 4 from http://www.php.net/downloads.php
If you are able to reproduce the bug with one of the latest
versions of PHP, please change the PHP version on this bug report
to the version you tested and change the status back to "Open".
Again, thank you for your continued support of PHP.
Previous Comments:
------------------------------------------------------------------------
[1999-11-14 03:45:49] joey@cvs.php.net
Can you verify if this bug still exists?
------------------------------------------------------------------------
[1999-11-11 18:18:11] joey@cvs.php.net
Marking 2109 as dup, adding info here:
Short Desc.:
while kills while loop (part 2)
[1999-08-10 04:10:06] commy_@hotmail.com
I think i found what the bug migh be.
This is a seudo code that shows what im am doing.
while (odbc_fetch_row($first_result)) {
... code ...
while (odbc_fetch_row($second_result))
{
... code ...
}
}
This example only returns one row (the
last) from the $first_result. It seems that the two
while loops with a odbc_fetch_row()
kills each other!?
I also tried with a "while" and "for"
loop and it gave the same
result. So it must be the
odbc_fetch_row() who screws up.
------------------------------------------------------------------------
[1999-08-05 14:24:53] slawrance@cvs.php.net
Are you using the same loop control variable in both loops
(assuming you're taking that approach)?
As an example, are you doing something like this:
$i = 0;
while ($i < 10) {
$i = 0;
while ($i < 20)
$i++;
$i++;
}
In that example, the second while loop would kill the one
on top due to the value of $i. Try double-checking your
code, and if it still doesn't work then post the code that can
reproduce misbehavior if possible :-)
------------------------------------------------------------------------
[1999-08-05 11:06:50] commy_@hotmail.com
Can't you have a While loop inside another While loop?
It seems that the second loop stops the first one!?
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/?id=1972&edit=1