alin19 Posted October 29, 2008 Share Posted October 29, 2008 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 More sharing options...
alin19 Posted October 29, 2008 Author Share Posted October 29, 2008 this is hapening on a linux server, almost same code on a windows server is working, the diference is that there are more querys Link to comment https://forums.phpfreaks.com/topic/130588-mysql-error/#findComment-677516 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.