Jump to content

mysql error


alin19

Recommended Posts

i have this function:

function deleteOrders($sock,$conexiune)

{

$cerereOrd=$conexiune->select("SELECT * FROM `ordine_clsters` WHERE `done`='nu'");

		if (count($cerereOrd)>0)

		foreach ($cerereOrd as $tran)

			{
					echo sizeof($cerereOrd);

					$trim="<m t='DeleteFuturesOrder'>

				   	<ms>".$tran['serialMarket']."</ms>

				   </m>";

				echo $trim;

					$order=toUTF($trim);

				if (socket_write($sock, $order)) 

					echo "sa facut trimiterea de ordin";
					else 

					{

					echo "a aparut eroare la trimitere ordin";

					}

					$cerereUpd="UPDATE `ordine_clsters` SET `done` = 'da' WHERE `id` =".$tran['id']." LIMIT 1";

					$conexiune->update($cerereUpd);

			}





}

 

and somethins it echo 1 even if there is no element where done ='nu;

 

and because of this i get some errors, my coll in the mysql table is like this:

 

done  varchar(10)  latin1_swedish_ci    No 

 

can have something to do with varchar?

Link to comment
https://forums.phpfreaks.com/topic/130588-mysql-error/
Share on other sites

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.