Jump to content

[SOLVED] How do you abort a while loop if a condition is met.


DeepakJ

Recommended Posts

How do you abort a while loop if a condition is met and the appropriate actions according to that loop have been taken.

while($row2=mysql_fetch_array($bResult)){
if ($row2['productid']="")
{
	$tableid = $row2['tableid'];
	$queryc = "UPDATE productid SET productid='$productid' WHERE tableid = $tableid";
}
}

 

I simply would like to abort the loop at the first instance of the nullstring. Help would be greatly appreciated.

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.